Created
September 2, 2015 06:00
-
-
Save mattetti/9aa9e7844c043c35f6a2 to your computer and use it in GitHub Desktop.
JXA (JS) automation script to play the "morning" playlist, only works on recent versions of OS X
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| app = Application('iTunes') | |
| app.activate() | |
| app.stop() | |
| playlist = app.sources["Library"].userPlaylists["morning"] | |
| try { | |
| playlist.play() | |
| } | |
| catch(err) { | |
| console.log("The playlist probably doesn't exist", err) | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment