With Apple’s notarisation, one has to add key/value pairs in the info.plist in order to make some features working (like NSAppleEventsUsageDescription to be able to send AppleEvents).
The only way I know to achieve this in Xojo, currently, is to have an info.plist file physically on disk (then dragged to the project).
Would it not be nice to have a simple editor, right in Xojo, to put key/value pairs to be added in the info.plist at compile time, allowing to get rid of these extra files laying around?
In my workflow, I also sometimes forget to turn the AppleScript switch on in AppWrapper. While it’s not the end of the world, I’d find it nice if AppWrapper could detect the presence of a NSAppleEventsUsageDescription key inside the info.plist file and switch AppleScript (in “capabilities”) on when there’s this key (without user interaction).
Thank you. Oddly enough, I’ve never tried scripting build automation (first time it’d solve a problem for me).
Well, a listbox with 2 columns (key and value), and “add” and “remove” buttons would suffice. Then, I guess the compiler would have no trouble in adding these to the info.plist file.
For simple projects, there would be no need for dictionary support. But even then, the listbox would be hierarchical.
Honestly, I don’t think it’s worth doing. Xcode’s plist editor is always going to be better, and keeping a plist file to merge in is a pretty low cost. It keeps Xojo focused on other things.
It can be done with App Wrapper, so the plist entries are configured with all the other settings you need to deliver your application.
If you want to manually edit the plist, use “Information Property List” on the “Edit” menu, otherwise many options are configured via checkboxes and fields in the main GUI.
you mean for this particular file you use xcode or in general you use xcode to manage all plist ?
Plus i was wondering what are the ways to create/read/write plist files in xojo ? might move some of my prefs to plist files
Official ways of editing plist files are through declares or plugins. I have the code in the Ohanaware App Kit to do this (which is used by App Wrapper).
Unofficially, you can edit the text based plist files via XML classes, however there’s also a binary format, which to the best of my knowledge is a private format.