Skip to content

Instantly share code, notes, and snippets.

@nalinbhardwaj
Last active March 3, 2022 22:23
Show Gist options
  • Save nalinbhardwaj/cfd613c513594889660461a997d99fae to your computer and use it in GitHub Desktop.
Save nalinbhardwaj/cfd613c513594889660461a997d99fae to your computer and use it in GitHub Desktop.
Spotify Commentary Skipper

Setup:

  1. Put skipper.scpt in any location you like
  2. Put com.nibnalin.SpotifyCommentarySkipper.plist in ~/Library/LaunchAgents: remember to replace the path for the skipper script. Note that this needs to be an absolute path for some unknown reason, so use the full path.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.nibnalin.SpotifyCommentarySkipper</string>
<key>ProgramArguments</key>
<array>
<string>/usr/bin/osascript</string>
<string>/Users/nibnalin/Documents/spotify-commentary-skipper/skipper.scpt</string>
</array>
<key>StartInterval</key>
<integer>2</integer>
<key>ThrottleInterval</key>
<integer>0</integer>
</dict>
</plist>
use AppleScript version "2.4"
use scripting additions
tell application "Spotify"
set c to the current track
if ("Commentary" is in name of current track) then
tell application "Spotify"
next track
end tell
end if
end tell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment