How to write preference files in the bundle of an app?

Hi all :slight_smile:

How to write the files of preferences (as the user defaults entries but without using them) in the bundle of the application?

Thanks :slight_smile:

I think you can’t instruct AS-Studio to read and write preferences to a place different from the prefs folder.
Here is a quick tip to access plist files using “defaults” but, as you know, it is not very flexible for lists or records, since it will return allways plain text:

--> for a file called "sample.plist" in the directory "path:to:"
set plistFile to "path:to:sample"
do shell script "defaults read " & quoted form of POSIX path of plistFile

Ok, thank you JJ for your answer. :slight_smile:

I continue to seek a solution, if I find something of interesting, I keep you informed here…

Gracias Señor :wink: