Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[apple] Add ability to delete a specific simulator runtime version #1278

Open
ivanpovazan opened this issue Sep 26, 2024 · 0 comments
Open
Assignees
Labels
apple iOS/tvOS/WatchOS/Mac Catalyst area enhancement New feature or request

Comments

@ivanpovazan
Copy link
Member

Description

This can be achieved through:

xcrun simctl runtime delete <simulator-build-version-number>

The <simulator-build-version-number> can be found by executing:

xcrun simctl runtime list -j

And looking up the build property for a simulator runtime entry.

Example

For example, for the following iOS 18.0 simulator runtime:

"40C50016-ECEE-439C-A27D-6F55716AD2F6" : {
          "build" : "22A3351",
          "deletable" : true,
          "identifier" : "40C50016-ECEE-439C-A27D-6F55716AD2F6",
          "kind" : "Disk Image",
          "mountPath" : "\/Library\/Developer\/CoreSimulator\/Volumes\/iOS_22A3351",
          "parentIdentifier" : "81A82E90-ACDD-47C8-A3B1-A93E7FC76A93",
          "parentImagePath" : "\/System\/Library\/AssetsV2\/com_apple_MobileAsset_iOSSimulatorRuntime\/cc1f035290d244fca4f74d9d243fcd02d2876c27.asset\/AssetData\/096-69246-684.dmg",
          "parentMountPath" : "\/Library\/Developer\/CoreSimulator\/Cryptex\/Images\/bundle\/SimRuntimeBundle-81A82E90-ACDD-47C8-A3B1-A93E7FC76A93",
          "path" : "\/Library\/Developer\/CoreSimulator\/Cryptex\/Images\/bundle\/SimRuntimeBundle-81A82E90-ACDD-47C8-A3B1-A93E7FC76A93\/Restore\/096-69245-692.dmg",
          "platformIdentifier" : "com.apple.platform.iphonesimulator",
          "runtimeBundlePath" : "\/Library\/Developer\/CoreSimulator\/Volumes\/iOS_22A3351\/Library\/Developer\/CoreSimulator\/Profiles\/Runtimes\/iOS 18.0.simruntime",
          "runtimeIdentifier" : "com.apple.CoreSimulator.SimRuntime.iOS-18-0",
          "signatureState" : "Verified",
          "sizeBytes" : 8361951702,
          "state" : "Ready",
          "version" : "18.0"
        }

Removing it would be achieved by executing:

xcrun simctl runtime delete 22A3351

This is useful for round-trip testing as after removing a said runtime it can be again installed via:

xharness apple simulators install ios-simulator-64_18.0

Additional notes

The <simulator-build-version-number> can be also found in https://devimages-cdn.apple.com/downloads/xcode/simulators/index2.dvtdownloadableindex

@ivanpovazan ivanpovazan added enhancement New feature or request apple iOS/tvOS/WatchOS/Mac Catalyst area labels Sep 26, 2024
@ivanpovazan ivanpovazan self-assigned this Oct 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
apple iOS/tvOS/WatchOS/Mac Catalyst area enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant