Pete Haworth wrote:

I guess the question here is where on earth are you supposed to put an
application's files if you want them to be available to all users?  It seems
like /Library/Application Support makes sense but apparently Apple have
decided otherwise.  I hope they have published a guideline somewhere that
explains how to handle this situation.

The rules haven't changed all that much; it's more like a prudent closure of a security exposure.

Allowing all processes to write to the system's Library is dangerous. Problem solved in Lion.

So what do we do?

Nothing much different from how it's been for the last decade:

Applications: most of an app's files go here, including the executable
              and other components like stack files and externals, all
              the essentials you app needs to run

Preferences:  user-specific settings for the app

Application Support: Apple says, "These are the files that your
              application creates and manages on behalf of the user
              and can include files that contain user data."

The use of App Support is rather loosely defined, its distinction from Preferences not exactly clear. Given that many users are comfortable ditching the prefs for an app, I would use App Support for those files which are more central to the app than preferences, need to be writable, and are not documents. For example, an RSS reader might puts its URL DB and cache in there.

But I must admit I've never yet had a need for it. It's rather specialized; the subset of things that aren't essential to running the app (which should be in the bundle) and aren't user-specific settings (which should be in Prefs) is slim.

If I did need to use it, I'd make sure the app contained copies of the files it needs to put there, checked for them at startup, and if not found would write the initial set of files to the user's App Support folder. By putting the smarts for this into the app, all users have the same starting point.

In the even slimmer case where you need to have one user's settings affect other users, I would consider the Shared folder. It may or may not be what Apple would suggest, but it's a very rare case anyway and AFAIK neither OS X, Window, or Linux provides a globally-writable space for such things other than the Shared folder or its equivalent on other platforms.

--
 Richard Gaskin
 Fourth World
 LiveCode training and consulting: http://www.fourthworld.com
 Webzine for LiveCode developers: http://www.LiveCodeJournal.com
 LiveCode Journal blog: http://LiveCodejournal.com/blog.irv

_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Reply via email to