Example app that illustrates how to get open-in-place to work well with iOS document providers.
It shows how to:
- invoke the document picker in open mode for files and directories
- receive open-in-place file references through Drag and Drop
- use and persist the security scoped URLs the document picker or Drag and Drop gives you
- work with a directory in a coordinated manner to stay in sync
- edit a text file in a coordinated manner such that your changes are written safely and such that outside changes appear in the editor automatically
- use the WorkingCopyUrlService file-provider SDK to fetch information about entries
Using the document picker to open directories will probably only work for a few document providers that happen to be Git clients. I am the author of Working Copy that supports this as does Git2Go.
Opening files and file packages (directories masquarading as files) should work for iCloud Drive and other well behaved document providers.
The excellent Textastic has been doing this for a while and my hope is that providing sample code will encourage others to follow suit.
A good place to start is at the top of ListController and EditController.
If you have any questions the easiest way to catch me is on Twitter as @palmin.