Do app updates overwrite the app's home directory?
I use the NSHomeDirectory()
function to get the app's home folder, and write to开发者_JS百科 the Documents directory within that. I'm curious, though, what happens when the user downloads an update for the app from the App Store? Will it all be deleted? When I delete the app on the device, then reinstall it, it's wiped out. So, I'm curious to know what will happen with an update. I can't find this in the documentation at all.
Stuff inside ~/Documents/
and the user preferences are preserved during update.
See the iOS File System Programming Guide.
精彩评论