Previously, I’d seen pathnames containing /private/tmp/ or /private/var/
Is /var/folders/ as the path for SpecialFolder.Temporary new? Or is it dependent on the OS version (I haven’t had a chance to try older versions of macOS).?
Thanks. I do use Temporary to save files. But I have methods in my app that let users display the contents of files, sometimes these are visible to the user and sometimes they are in the Temporary folder. I need to be able to tell if the file is in the Temporary folder so they can be moved to a user-accessible location like Documents. I guess I’ll have to add /var/folders/ to the list of paths that contain temporary folderItems.
Note: I believe that the Xojo Shell may not have the same environment as the Terminal app, so be don’t make any assumptions. I’m pretty sure there is, however, only one $TMPDIR (and I think it’s per-user but am not sure)
Be warned, since 10.14, I have a handful of customers who’ve experienced the in-ability to access the temporary folder from within my applications. The solution I found (unless their temporary folder is full) is to use a different API via declares.
Unless you are performing atomic saving, I’d recommend creating a subfolder within your Application’s “Application Support” folder, or the cache folder (which is also specific to your application).