![]() (In writing this script I discovered that AppleScript does let you compare dates, using the fantastic construction “if is greater than. If so, the script compares that folder’s modification time to the contents of the variable theNewestDate, and if it’s more recent, that variable is updated to the modification time of the newer folder. The script then loops through those contents to see if there’s a Logic project file inside. The next part loops through those folders, getting their contents. If theDate is greater than theNewestDate then Set theDate to (get modification date of theFolder) If kind of the_item is "Logic X Project" then Set folder_contents to entire contents of theFolder This first part gets a list of folders on the Desktop, and then sets a variable to a very old date for reasons that will make sense in a little while. Set theNewestDate to date "Tuesday, Octoat 7:00:00 AM" Set folder_list to folders of (path to desktop folder as alias) AppleScript, while perhaps not the best tool for this job, is the tool that I know how to use. In the end I realized that what I needed to do was find the most recently modified folder on my Desktop that contained a Logic X project file. In any event, I now needed to write the script, which means I needed to figure out the specific rules that would define the right destination folder. ![]() So I asked Jon, is there any way to programmatically define where Default Folder opens? His response was to send me a development build of Default Folder that would allow the default location to be overridden with an AppleScript, a “hidden” feature now available in version 5.3.7 of Default Folder X. When I’m recording ads and other audio for podcasts, I invariably end up saving it all in the Audio Files folder in the project folder for my current Logic project, which is invariably sitting on the Desktop. I realized that in at least one app I use, there’s a very common location I want to save all my files-but the location is not persistent. It’s a utility that lets you set a different default location for the Open/Save dialogs in every app you use, and provides some other clever features like clicking on an open Finder window to change the Open/Save dialog to that window’s location.įor the first time in years, a few weeks ago I had a feature request for Jon Gotow, the developer of Default Folder. Clair Software’s Default Folder since the days of System 7. ![]() Note: This story has not been updated since 2020. Scripting a save location within Default Folder X ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |