dougscripts.com

frontpage : faqs : here

Download FAQ for Music and TV AppleScripts

Here is everything you need to know about downloading and installing the Music/TV AppleScripts from this site. (For iTunes AppleScripts in macOS 10.14 and earlier see Download FAQ + Video for iTunes AppleScripts.)

 

Scripts for iTunes Don't Run in macOS 10.15 and Later

AppleScripts created to work with iTunes will not work in macOS 10.15 Catalina and later. They can't. There is no iTunes application for them to work with. They won't even launch properly. So don't bother downloading them unless it is to a computer running macOS 10.14 Mojave or earlier, where they will still function properly with iTunes.

 

Check for Updates

Download the Doug's Check For All Updates applet to check if any of your current AppleScripts from this site have newer versions.

 

You Already Have AppleScript

AppleScript is part of the macOS so there's nothing to install except the scripts you'll download.

 

M1 Macs, Universal Builds and Rosetta 2

Actually, there may be something else to install if you are using an M1 (or better) Mac: the Rosetta 2 software that enables software built on an Intel Mac to run on Apple silicon Macs. While most modern versions of AppleScripts at this site are Universal builds—that is, they are able to run on both Apple silicon and Intel processors—you may still have an older Intel version of an AppleScript and this will compel the installation of Rosetta 2. Again, be sure to check for updates.

 

First-Timer? Prepare the Installation Location

NOTE: For the sake of brevity, I'll only describe installing Music AppleScripts. But whether you are installing AppleScripts for Music or AppleScripts for TV, the method is practically the same. The only difference is that Music scripts will be in a "Music" folder and TV scripts will be in an "Apple TV" folder.



Scripts in the Music Script menu are listed like menu items.

AppleScripts for Music will be accessible from the Music app's Script menu when they have been installed in a special "Scripts" folder—actually, installed in one or the other of two special "Scripts" folders. Whichever one you use depends on who'll be using the scripts.

• All Users
If you want an AppleScript for Music to be available for all user accounts on your machine you'll install it once in the "Scripts" folder located in your [startup disk]/Library/Music/ folder. This Library folder is often called the local Library folder.

If there is no "Music" folder or "Scripts" folder in the [startup disk]/Library/ folder then create them.

• Single User
To make an AppleScript accessible for just a single user then you'll install it in the "Scripts" folder in that user's [username]/Library/Music/ folder. The user Library folder is hidden by default. One way to make it visible is to press and hold the Option key on your keyboard and select Go > Library from the Finder.

If there is no "Music" folder or "Scripts" folder in the [username]/Library/ folder then create them.

The user Library install location, [username]/Library/Music/Scripts/, is what I always recommend and therefore is the presumptive install location. However, I have heard reports that scripts installed in the user Library location may not appear in the Script menu right away...or at all. In such a case, use the local Library install location.

Some scripts have been designed to work with both the Music and the TV app. Such scripts will only work with Music by default. In order for them to work with the TV app, they must be installed in the [username]/Library/Apple TV/Scripts/ folder. If necessary, sImply create a copy of the script and put it there. Just don't run more than one copy at a time.

Some AppleScript applets and droplets don't need to be installed in a "Scripts" folder and instead can be installed wherever it is easiest to access them. See the Read Me that accompanies the script for install options that may be available.

• Clean installations of the macOS will not create the "Music" (or "Apple TV") folder in either "Library" folder. I've written about this here. That is why you will have to create the "Music" (or "Apple TV") folder.

It may be that settings you have entered elsewhere prohibit using the Option key as the shortcut to reveal the Library item in the "Go" menu. If the Library folder does not display in the Finder's "Go" menu with the Option key pressed, try the Shift key (see this tip from Rob Griffiths).

• But Wait! There's More! There are two other locations in which AppleScripts can be installed so that they will appear in the system-wide Script menu that appears at the right end of the Menu Bar. This can be set up by going to Script Editor's Preferences, selecting the General tab and check marking "Show Script menu in menu bar". Scripts will appear in this menu when they are installed in either the [startup disk]/Library/Scripts/ folder or the [username]/Library/Scripts/ folder. For more flexibility, add an "Applications" folder containing application-named folders. For example: [username]/Library/Scripts/Applications/Music/. Scripts can be placed in the the application-named folders so that they only appear when that app is frontmost.

As mentioned earler, I generally recommend installing scripts in [username]/Library/Music/Scripts/.

 

Download and Install

Once you have found a script on the site that you'd like to use, click on the red download button in the top-right corner of its entry page:



Typical script entry.

(Older versions of the script may be available as direct downloads and will be listed in the "Particulars:" section on the entry page.)

A .dmg file will be downloaded to your browser's "Downloads" folder. (You know where that is, right?) A .dmg file is a Disk Image File. Some modern browsers may open this .dmg file automatically. In Safari, you can select the .dmg file from the Show Downloads button and double-click it. Otherwise, double-click the .dmg file in the Finder. It will mount in the Finder, like a CD-ROM disk or external drive:



The disk image window when mounted and opened. Instructions are right on the can.

To install the files/folders, drag the items from the disc image window to the "Scripts" folder you prepared (as described above). The .rtfd file is the script's "Read Me" file and can be saved anywhere. But keeping it with the script in the "Scripts" folder is probably as good as any other location.

Finally, close the disk image window and unmount it (click the arrow button to the right of its name in the Finder's sidebar under "Locations").

You can backup the .dmg file, if that's what you do with your downloads. Otherwise, you can Trash it.

 

Notarization Required in macOS 10.15 Catalina and later

As of macOS 10.15 Catalina, developers are required to have Apple "notarize" their software. Notarization is a Gatekeeper security feature whereby a developer submits their software to Apple to check for malicious software. All scripts for macOS 10.15 and later uploaded to this site have been notarized by Apple.

 

AppleEvent Sandboxing (macOS 10.14 Mojave and later)

When you launch an AppleScript downloaded from this site for the first time you will see an alert with a message like this:

This is a layer of security which ensures that you are made aware of when a script needs to access certain resources on your computer. In the case of scripts from this site, they will inform you that the script needs to interact with Music or TV (and perhaps the Finder or other applications if so required). While this may seem self-evident it is certainly possible that a bad actor could convince you to launch a script from some other site that does not do what it says and instead does something else nefarious.

This alert will only appear once. If you happened to click "Don't Allow" and want to permit access for a particular app, head to System Preferences > Security & Privacy > Privacy > Automation, you will see the list of apps that use automation and which apps they target:

If necessary, put a checkmark next to the app you want to allow access to in the script's entry. Or you can uncheck an app if you suspect the listed AppleScript is up to some funny business.

Additional Security Concerns: A very small number of AppleScripts from this site will need access to "System Events", an Accessibility application that can be controlled by AppleScript. Controlling "System Events" will enable a script to push buttons, click menu items and perform other interface-related actions—strictly related to the script's essential operation only. In such a case, an additional alert will ask you to change a setting in the System Preferences > Security & Privacy > Privacy > Accessibility panel.

Click the "Open System Preferences" button and the Accessibility panel will open and be selected.

Click on the lock to enter your password to enable the list of apps. Then, put a checkmark in the checkbox next to the script asking for access. Dismiss System Preferences.

This will only occur once; your computer will allow the script to operate without asking for security clearances again.

BUT. Because all of these clearances occur when a script first launches, the script will probably not complete its start-up procedure correctly and so you will have to re-start the script.

 

Versioning

Like most applications, AppleScripts need to be updated on occasion. This can be due to updates and changes to the Music app or TV app itself, or because the author has discovered bugs or a better way to write the routines. In any case, AppleScripts from this site are occasionally updated. You can find the version number for a script in several places:

  • In the script file's "Get Info" window
  • In the "Version" column of a FInder window in List View
  • In the name of the downloaded .dmg file
  • In the title of the script's most current Read Me documentation

Download the Doug's Check For All Updates applet to check if any of your current AppleScripts from this site have newer versions.

 

Read Me Documentation

Not for nothin', but I put a lot of time into creating the Read Me document for each script—the accompanying .rtfd document—so it is to your advantage to read it and keep it handy for future reference. I know how people feel about Reading the F'ing Manual (and I do try to make the scripts I write as intuitive to use as possible), but it's pretty silly not to.

  • The Read Me is available to view as a PDF in your browser in the "Info" section of its online entry.
  • Each script's Read Me is named using the name of the script so it will be easy to find in the Music Scripts folder after installing.
  • The Read Me contains information on installing and using the script and its version history. It also contains some embedded links to helpful information and my RSS feeds. Additionally, it contains the URL to the script's entry at this site, should you wish to return to the entry to check for an update or to recommend the script to someone.

Problems?

I understand that I can't account for everyone's computer set-up. If you have any problems installing or using a script from this site, let me know. My contact info is in every Read Me. Otherwise, have fun!

Site contents © 2001 - 2024 (that's right: 2001) Doug Adams and weblished by Doug Adams. Contact support AT dougscripts DOT com. About.
All rights reserved. Privacy.
AppleScript, iTunes, iPod, iPad, and iPhone are registered trademarks of Apple Inc. This site has no direct affiliation with Apple, Inc.
The one who says "it cannot be done" should not be interrupting the one who is doing it.