Reputation: 903
I’m creating a .pdf reader for tvOS. I’d like to store the .pdfs in an iCloud Drive folder and access them read-only. Not suprisingly, I’m encountering difficulty getting iCloud to work: FileManager.default.url(forUbiquityContainerIdentifier: nil)
always returns nil.
I’m assuming that I need to added the entry to info.plist (why doesn’t Xcode do this?) I’m including the following. The key matches my bundle ID with a prefix of ‘iCloud’.
<dict>
<key>iCloud.com.spiffcleanser.books</key>
<dict>
<key>NSUbiquitousContainerIsDocumentScopePublic</key>
<true/>
<key>NSUbiquitousContainerName</key>
<string>books</string>
<key>NSUbiquitousContainerSupportedFolderLevels</key>
<string>Any</string>
</dict>
</dict>
I have a number of questions but all are related so I hope its acceptable to ask them all at once. At this point I’m merely trying to get the container URL.
Thanks for any help.
Upvotes: 0
Views: 470
Reputation: 903
I've solved this. iCloud support for documents is not available on tvOS. This is due to only minimal local storage being available.
Upvotes: 1