Skip to content

Instantly share code, notes, and snippets.

@derhuerst
Created January 31, 2016 16:37
Show Gist options
  • Save derhuerst/c7f5683c435d4c83943a to your computer and use it in GitHub Desktop.
Save derhuerst/c7f5683c435d4c83943a to your computer and use it in GitHub Desktop.
get the current track from Spotify
tell application "Spotify"
set tNumber to track number of current track as integer
set tDisc to disc number of current track as integer
set tDuration to duration of current track as integer
set tName to name of current track as string
set tArtist to artist of current track as string
set tAlbum to album of current track as string
set tAlbumArtist to album artist of current track as string
set meta to tNumber & ";" & tDisc & ";" & tDuration & ";" & tName & ";" & tArtist & ";" & tAlbum & ";" & tAlbumArtist & "
"
log meta
end tell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment