0

I am doing image caching and I am saving the files to a temporary directory NSTemporaryDirectory. Its seen in log as /var/folders/.... .Where is this thing present. I am currently doing all this in the simulator?

wolverine
  • 2,967
  • 5
  • 31
  • 35

1 Answers1

1

You can use the following line to find out:

NSLog(NSTemporaryDirectory());

Gives me the path path like this: /var/folders/c9/c9ooh947H2WloiBIdpTdcU+++TI/-Tmp-/

You can browse there in terminal:

cd /var/folders/c9/c9ooh947H2WloiBIdpTdcU+++TI/-Tmp-/

/var folder is hidden on MacOS and is not shown in Finder by default. You can switch on showing hidden folders using this terminal command:

defaults write com.apple.finder AppleShowAllFiles -bool true

After that it must become visible in Finder in root folder

Vladimir
  • 170,431
  • 36
  • 387
  • 313