a pastebin project

MacIrssi and iTunes applescript

  1. -- small script to use for displaying iTunes track+artist+album wherever you open an applescript
  2. -- when iTunes is running
  3. tell application "iTunes"
  4.        
  5.         if player state is playing then
  6.                 -- get track, artist and album
  7.                 set currenttrack to the name of current track
  8.                 set currentartist to the artist of current track
  9.                 set currentalbum to the album of current track
  10.                 -- show track, artist and album
  11.                 set titleinfo to (currenttrack & " - " & currentartist & " | " & currentalbum)
  12.                 set output to titleinfo
  13.         end if
  14. end tell

advertising

Create a Paste

Please enter your new post below (or upload a file instead):





Please note that information posted here will not expire by default. If you want it to expire, please set the expiry time above. If it is set to expire, web search engines will not be allowed to index it prior to it expiring. Items that are not marked to expire will be indexable by search engines. Be careful with your passwords.

fantasy-obligation