Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Controlling iTunes from the Terminal' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Controlling iTunes from the Terminal
Authored by: the.hudi on Jun 18, '08 05:13:04AM
another suggestion: For the help:

echo " playlist = Show playlists saved in iTunes.";
And the code for showing available playlists, if there is no parameter given.

## addition playlist of choice
"playlist" )
if [ -n "$2" ]; then
echo "Changing iTunes playlists to '$2'.";
osascript -e 'tell application "iTunes"' -e "set new_playlist to \"$2\" as string" -e "play playlist new_playlist" -e "end tell"; 
break ;
else
# Show available iTunes playlists.
echo "Playlists:";
osascript -e 'tell application "iTunes"' -e "set allPlaylists to (get name of every playlist)" -e "end tell";
break;
fi
break;;


[ Reply to This | # ]