Skip to content

Instantly share code, notes, and snippets.

@srbaker
Last active August 29, 2015 14:04
Show Gist options
  • Save srbaker/988ea77308e7978ccfa5 to your computer and use it in GitHub Desktop.
Save srbaker/988ea77308e7978ccfa5 to your computer and use it in GitHub Desktop.
Automatically double the volume when Won't Get Fooled Again is playing.
(*
In response to: https://twitter.com/martinfowler/status/489168910147928064
Run this after pressing play in iTunes.
*)
tell application "iTunes"
activate
set original_volume to sound volume
repeat while player state is playing
if (get name of current track) is "Won't Get Fooled Again" then
if the sound volume is greater than 51 then
set sound volume to 100
else
set sound volume to (sound volume * 2)
end if
else
set sound volume to original_volume
end if
end repeat
end tell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment