Delete app from OSX simulator in Xcode - xcode

How do i delete an app from the OSX simulator like on the iOS simulator??
I want to delete an app due to the change of Core Data xcdatamodeld but i can't find a way.
Thanks in advance

For macOS Monterey and Big Sur, the location links to the devices folder location:
~/Library/Developer/CoreSimulator/Devices/{device_uuid}/data/Containers/Data/Application/
On MacOS Mojave 10.14.4 the folder is in the following location:
~/Library/Containers/com.yourcompany.yourapp/

As playitgreen mentioned in one of the comments, the way to delete data relating to your OSX app is by removing the folder/.storedata file from:
~/Library/Application Support/<YOUR OSX APP BUNDLE NAME>/
for example:
~/Library/Application Support/com.yourcompany.yourapp/
All credit to playitgreen

Specifically for Catalyst apps in macOS 10.15 (Catalina) and Xcode 11.2.1.
I tried right-clicking on the app's icon in the dock and then Options -> Show in Finder. I deleted all the files there and ran again from Xcode. The files returned and the app still had the data from before.
In ~/Library/Containers I found a folder called maccatalyst.<my_apps_bundle_identifier>. I deleted the files contained there and when I reran the app from Xcode the files returned and original data was gone. So that seems to be the way.
~/Library/Containers/maccatalyst.<app_bundle_identifier>

There are 2 solution:
When running the app press CMD + SHIFT+ H (simulates a home button press), then you can remove it by long press like on the phone
Remove the appropriate app foler from ~/Library/Application Support/iPhone Simulator/<ios_version_that_you_use>

Related

Flutter: XCode error "Unable to boot the Simulator"

Iam running the latest OSX/Flutter/XCode Versions using flutter, android studio and firebase and 1 hour ago everthing works perfectly.
Then i rebooted my macbook and when i try to launch an ios simulator i get this error "Unable to boot the simulator".
The following steps shows no solution:
Reinstall the ios simulator
Flutter clean and pub get
Updating comand line tools 13.3.1 (13E500a)
Run invalid cache of android studio
I found the problem also on stackoverflow but all sugestions does not working.
Any ideas?
Let me know if you need more information!
Thank you
NO NEED TO UNINSTALL XCODE! Though I know the contributor already has solved the issue, I'm happy if this answer will help someone else.
Go to [About this Mac > Storage > Manage > Developer]
Delete all the content (no worries!)
You can delete xcode cache and it will work,
by going to
About this Mac > Storage > Manage > Developer or any folder you choosed for development when installing xcode and flutter then Delete XCode Cache.
Step 1:
Go to About this Mac
Step 2:
Go to Storage
Step 3:
Delete all the content Or Delete XCode Cache
You can just clean your Xcode Caches, and that will do the trick,
About this Mac
Storage
Developer
XCode Caches
For me it was not necessary to delete XCode. I could solve it with this:
1: Click on "About this Mac" in the top left corner
2: Click on "Storage"-Tab
3: Click on "Manage"-Button
4: Click on "Developer"-Tab
5: Right click on all the data and "Delete"
For Mac Ventura 13.0 OS and higher -> Click apple logo on top left of your Mac
System Settings > search Storage > Developer
Then delete Xcode Caches
Product-> Clean Build Folder works for me!
After checking some other comments, it seems uninstalling XCode is not necessary.
The issue is not directly related to Flutter but it is related to the XCode 13.3.1 with the Simulator, specially for iPhone and iPad (tvOS and watchOS should have no issue so far).
Somehow the existing files during the security update causes the simulator to get corrupted.
As temporary workaround, you can try the following steps:
Uninstall XCode by moving from Applications folder to the Trash
Empty the Trash
Open the Mac Storage Management and go to the Developer in the sidebar
Delete everything from the Developer Section
Download Xcode 13.1 from Apple Developers and not the stable release from App Store
Extract the downloaded Xcode_13.1.xip file, i actually recommend via terminal by using xip -x Xcode_13.3.1.xip, and take in mind the extraction uses 100GB and it takes up to 2 hours to complete. You are going to have this message at the beggining xip: signing certificate was "Software Update" (validation not attempted), but you can ignore since this is expected.
Finally, move the extracted XCode file to the Applications folder
Run sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer
Run sudo xcodebuild -runFirstLaunch

Unable to update to Xcode 8

I would like to update to Xcode 8, but when I start the App Store it just shows me an Open button, but my existing Version is 7.3.1
The requirements should be El Capitan 10.11.5 - I have 10.11.6 installed.
Why is there no Update button?
Check if you have multiple installations of Xcode on your system. The App Store often gets confused and loads one you're not considering, such as the version on your back up drive. It's possible it has updated a different installation than the one it launches as well.
Executing the following command in a terminal window should list all installations of Xcode the App Store may find.
mdfind "kMDItemCFBundleIdentifier == 'com.apple.dt.Xcode'"
When you have Xcode open (from hitting Open in the store), right click the Xcode icon on your dock, select Options, and Show in Finder. Does the installation it shows match up with the one you expected it to launch?
If you specifically open each Xcode installation the mdfind command found, are any of them Xcode 8?
You can control which installation of Xcode the App Store will update. Check each of the app folders, and look for a Contents/_MASReceipt folder. Ensure the installation you want to update has that (and a receipt file inside that), and delete the _MASReceipt folder for all of the other versions.
Now the App Store app should update the correct installation for you.
All I had to do was restart my mac. Then, went to the App Store and saw "Update" instead of "Open".

Updating XCODE using different apple account

I have MAC OS 10.7.3. xcode 4.3.1 installed using different apple id as my macbook pro was used previously by my friend. Now when i try to upgrade Xcode to 4.3.2 it asking credentials for my friends account. Unfortunately App store clearly says you can upgrade an app using the account which was used to install the app.
How can i upgrade Xcode using my credentials?
Thanks in advance.
I am sure you would have solved this by now but just posting the solution here that worked for me..
Open Finder and navigate to Applications,
Ctrl+Click the application and choose "Show Package Contents" (Xcode in this case),
Expand the Contents directory and click the _MASReceipt directory to select it, Type Command+Delete to
delete the directory permanently---you will be prompted for your
credentials since this is a protected file.
Quit and restart
AppStore, then find the application. You can update with your new id now without deleting the old version of the app
Hope this helps someone coz it took me a while to figure out !!
Unfortunately had to answer my own question,
Simple Answer: NO, You cannot update xcode installed from another account.
Solution is to delete the existing installation and re-installing from new account.
To delete the existing installation, you need to delete it from Launch pad. You can do this by locating xcode icon in launch pad, long click on the icon till it starts dancing. Then delete it and wait for a while till the xcode.app is deleted from /Application. If you manually delete xcode.app from /Application, App store will continue to think its installed and will not allow you to reinstall in future.
Above solution is assuming you have installed xcode from the mac app store, usually versions later than 4.2. For earlier versions, just deleting /Application/xcode folder should work.
The solution is found:
I had this bug, it's related to Spotlight. The App Store used Spotlight in some way. My fix was to add the entire HD to the "Privacy" tab in the Spotlight System prefs pane, close the prefs and wait 30 seconds, re-open and remove your HD from the Privacy tab. Spolight begins reindexing. Re-opened the App Store and problem was fixed! Posting this here for others who might search later on. Also filed a bug report with Apple.
Source: https://discussions.apple.com/thread/2806858?start=0&tstart=0

Xcode Application sandbox folder doesn't show

I have Mac OS 10.7.3, with Xcode 4.3 , I am not able to see iPhone simulator folder in Application Support folder on MACINTOSH HD drive.
MACINTOSH HD/Library/Application Support/
There is no Library folder in User directory either.
Please help Let me know the solution.
Thanks
The Simulator is stored in ~/Library/Application Support/iPhone Simulator
To see the Library Folder in your user directory you need to choose the Go menu in finder, then hold down the option key on your keyboard and then choose Library, because Apple has hidden it in Lion.
You can also go to the Finder and use the keyboard shortcut ⌘-Shift-G. Paste ~/Library/Application Support/iPhone Simulator into the dialog box and click Go.

No iphone simulator folder in home library > Application support

I installed the xcode_4.3.1_for_lion.dmg on my mac 10.7.3. I need an iphone simulator folder to install the iapps. No iphone simulator folder in Application support
~/Library/Application Support/?
Checking in home library only.. ~/Library/...
Is there any way to check this?
I think this is a duplicate of How to install iPhone application in iPhone Simulator. I don't see any method of flagging a question as duplicate, though.
See my answer at following post.You should clear your trash folder and reset it.For more detail click below link.
No iphone simulator folder in Application support

Resources