Skip to content

Instantly share code, notes, and snippets.

@cpoliver
Created September 5, 2017 12:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save cpoliver/f231f69a785ec795ebb4b1a780ba0db0 to your computer and use it in GitHub Desktop.
Save cpoliver/f231f69a785ec795ebb4b1a780ba0db0 to your computer and use it in GitHub Desktop.
BetterTouchTool Spotify Script
on is_running(appName)
tell application "System Events" to (name of processes) contains appName
end is_running
if is_running("Spotify") then
tell application "Spotify"
set currentArtist to artist of current track as string
set currentTrack to name of current track as string
return currentArtist & " - " & currentTrack
end tell
else
return " "
end if
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment