In iOS 7, the document directory of the iOS simulators can be found in:
/Users/Sabo/Library/Application Support/iPhone Simulator/
However, in iOS 8 Beta Simulator, I can't find the corresponding directory for iOS 8 in the directory above.
Where's the document directory path for the iOS 8 Simulator?
The simulator directory has been moved with Xcode 6 beta to...
Browsing the directory to your app's Documents folder is a bit more arduous, e.g.,
Try
~/Library/Developer/CoreSimulator/Devices/
NSLog
below code somewhere in "AppDelegate", run your project and follow the path. This will be easy for you to get to the documents rather than searching randomly inside "~/Library/Developer/CoreSimulator/Devices/"Objective-C
Swift
If you are using Swift 1.2, use the code below which will only output in development when using the Simulator because of the
#if
#endif
block:Copy your path from "/Users/ankur/Library/Developer/CoreSimulator/Devices/7BA821..." go to "Finder" and then "Go to Folder" or command + shift + g and paste your path, let the mac take you to your documents directory :)
If you like to go into the app folders to see what's going on and don't want to have to go through labyrinthine UUDID's, I made this: https://github.com/kallewoof/plget
and using it, I made this: https://gist.github.com/kallewoof/de4899aabde564f62687
Basically, when I want to go to some app's folder, I do:
The
./app.sh
part syncs the links. It is necessary basically always nowadays as apps change UUID for every run in Xcode as of 6.0. Also, unfortunately, apps are by bundle id for 8.x and by app name for < 8.Based on Ankur's answer but for us Swift users:
Put it inside ViewDidLoad and it will print out immediately upon execution of the app.
Just write bellow code in AppDelegate -> didFinishLaunchingWithOptions
Objective C
Swift 2.X
Swift 3.X
Swift 4.2
Output
/Users/mitul_marsonia/Library/Developer/CoreSimulator/Devices/E701C1E9-FCED-4428-A36F-17B32D32918A/data/Containers/Data/Application/25174F64-7130-4B91-BC41-AC74257CCC6E/Documents
Copy your path from "/Users/mitul_marsonia/Library/Developer/CoreSimulator/Devices/E701C1E9-FCED-4428-A36F-17B32D32918A..." go to "Finder" and then "Go to Folder" or command + shift + g and paste your path, let the mac take you to your documents directory