From dd64a39c7e928620bb43bd12c5d066c1c95517d2 Mon Sep 17 00:00:00 2001 From: kidpixo Date: Mon, 3 Jun 2013 14:06:33 +0200 Subject: [PATCH 1/4] forked original with shortcuts Added shortctucts: p : play|resume|unpause pa : pause s : stop n : next pr : prev i : info se : search sh : shuffle r : repeat pl : playlist pls : playlists v : vol|volume m : mute um : unmute sv : sysvol|sysvolume sm : sysmute sum : sysunmute --- itunes | 42 +++++++++++++++++++++--------------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/itunes b/itunes index 0ac91b1..3f55da3 100755 --- a/itunes +++ b/itunes @@ -716,31 +716,31 @@ function _dispatch() { shift case "$cmd" in # Navigation commands. - play|resume|unpause) + p|play|resume|unpause) _cmd_play "$@" ;; - pause) _cmd_pause "$@" ;; - stop) _cmd_stop "$@" ;; - next) _cmd_next "$@" ;; - prev) _cmd_prev "$@" ;; - info) _cmd_info "$@" ;; - search) _cmd_search "$@" ;; - shuffle) _cmd_shuffle "$@" ;; - repeat) _cmd_repeat "$@" ;; - playlist) _cmd_playlist "$@" ;; - playlists) _cmd_playlists "$@" ;; + pa|pause) _cmd_pause "$@" ;; + s|stop) _cmd_stop "$@" ;; + n|next) _cmd_next "$@" ;; + pr|prev) _cmd_prev "$@" ;; + i|info) _cmd_info "$@" ;; + se|search) _cmd_search "$@" ;; + sh|shuffle) _cmd_shuffle "$@" ;; + r|repeat) _cmd_repeat "$@" ;; + pl|playlist) _cmd_playlist "$@" ;; + pls|playlists) _cmd_playlists "$@" ;; # Volume commands. - vol|volume) _cmd_volume "$@" ;; - mute) _cmd_mute "$@" ;; - unmute) _cmd_unmute "$@" ;; - sysvol|sysvolume) + v|vol|volume) _cmd_volume "$@" ;; + m|mute) _cmd_mute "$@" ;; + um|unmute) _cmd_unmute "$@" ;; + sv|sysvol|sysvolume) _cmd_sysvolume "$@" ;; - sysmute) _cmd_sysmute "$@" ;; - sysunmute) _cmd_sysunmute "$@" ;; + sm|sysmute) _cmd_sysmute "$@" ;; + sum|sysunmute) _cmd_sysunmute "$@" ;; # Application commands. - open) _cmd_open "$@" ;; - quit) _cmd_quit "$@" ;; - show|reveal) _cmd_show "$@" ;; - hide) _cmd_hide "$@" ;; + o|open) _cmd_open "$@" ;; + q|quit) _cmd_quit "$@" ;; + sw|show|reveal) _cmd_show "$@" ;; + h|hide) _cmd_hide "$@" ;; # Extra commands. version) _cmd_version "$@" ;; ""|help) _cmd_help "$@" ;; From 1d4184837f6ab66ec8726c9698207c098a201f4d Mon Sep 17 00:00:00 2001 From: kidpixo Date: Mon, 3 Jun 2013 14:21:47 +0200 Subject: [PATCH 2/4] new readme --- README.mkdn | 51 ++++++++++++++++++++++++++++++--------------------- 1 file changed, 30 insertions(+), 21 deletions(-) diff --git a/README.mkdn b/README.mkdn index 0dc1254..84b3be5 100644 --- a/README.mkdn +++ b/README.mkdn @@ -1,3 +1,12 @@ +I just addeded some extra shortcuts. In my system "itunes" is aliased as "i" so + +``` + > i p +``` + +plays a song. Al the credits to the original project! + + Bash iTunes =========== @@ -8,31 +17,31 @@ Currently it supports the following commands: ``` Navigation commands: - play Start or resume playing. - pause Pause playing. - stop Stop playing. - next Skip to next track. - prev Skip back to previous track. - info View info about current track. - search Search for tracks. - shuffle View or set shuffle status. - repeat View or set repeat status. - playlist View or choose playlist. - playlists List all playlists. + p play Start or resume playing. + pa pause Pause playing. + s stop Stop playing. + n next Skip to next track. + pr prev Skip back to previous track. + i info View info about current track. + s search Search for tracks. + sh shuffle View or set shuffle status. + r repeat View or set repeat status. + pl playlist View or choose playlist. + pls playlists List all playlists. Volume commands: - vol[ume] View or adjust iTunes volume 'up', 'down' or percentage. - mute Mutes iTunes. - unmute Unmutes iTunes, restoring previous volume level. - sysvol[ume] View or adjust system volume 'up', 'down' or percentage. - sysmute Mute system sound. - sysunmute Unmute system sound. + v vol[ume] View or adjust iTunes volume 'up', 'down' or percentage. + m mute Mutes iTunes. + um unmute Unmutes iTunes, restoring previous volume level. + sv sysvol[ume] View or adjust system volume 'up', 'down' or percentage. + sm sysmute Mute system sound. + sum sysunmute Unmute system sound. Application commands: - open Start iTunes running. - quit Quit iTunes. - show Hide the iTunes window. - hide Show the iTunes window. + o open Start iTunes running. + q quit Quit iTunes. + sw show Hide the iTunes window. + h hide Show the iTunes window. Additional commands: version Show version information and exit. From e0f1f8459c098428b3415b130400fda2f530465b Mon Sep 17 00:00:00 2001 From: kidpixo Date: Wed, 5 Jun 2013 12:00:52 +0200 Subject: [PATCH 3/4] new help with actual shortcuts --- .gitignore | 10 ++++++++++ itunes | 42 +++++++++++++++++++++--------------------- 2 files changed, 31 insertions(+), 21 deletions(-) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..24a9198 --- /dev/null +++ b/.gitignore @@ -0,0 +1,10 @@ +# OS generated files # +###################### +.DS_Store +.DS_Store? +._* +.Spotlight-V100 +.Trashes +Icon? +ehthumbs.db +Thumbs.db diff --git a/itunes b/itunes index 3f55da3..6ff171f 100755 --- a/itunes +++ b/itunes @@ -34,31 +34,31 @@ Switches: -d Enable debug messages, additional -d options increase verbosity. Navigation commands: - play Resume playing or choose track. - pause Pause playing. - stop Stop playing. - next Skip to next track. - prev Skip back to previous track. - info View info about current track. - search Search for tracks. - shuffle View or set shuffle status. - repeat View or set repeat status. - playlist View or choose playlist. - playlists List all playlists. + p play Resume playing or choose track. + pa pause Pause playing. + s stop Stop playing. + n next Skip to next track. + pr prev Skip back to previous track. + i info View info about current track. + se search Search for tracks. + sh shuffle View or set shuffle status. + r repeat View or set repeat status. + pl playlist View or choose playlist. + pls playlists List all playlists. Volume commands: - vol[ume] View or adjust iTunes volume 'up', 'down' or percentage. - mute Mutes iTunes. - unmute Unmutes iTunes, restoring previous volume level. - sysvol[ume] View or adjust system volume 'up', 'down' or percentage. - sysmute Mute system sound. - sysunmute Unmute system sound. + v vol[ume] View or adjust iTunes volume 'up', 'down' or percentage. + m mute Mutes iTunes. + um unmute Unmutes iTunes, restoring previous volume level. + sv sysvol[ume] View or adjust system volume 'up', 'down' or percentage. + sm sysmute Mute system sound. + sum sysunmute Unmute system sound. Application commands: - open Start iTunes running. - quit Quit iTunes. - show Hide the iTunes window. - hide Show the iTunes window. + o open Start iTunes running. + q quit Quit iTunes. + sw show Hide the iTunes window. + h hide Show the iTunes window. Additional commands: version Show version information and exit. From 6bfd6d0edf8ef109725cd72c71200e206e67fe37 Mon Sep 17 00:00:00 2001 From: kidpixo Date: Wed, 5 Jun 2013 12:04:20 +0200 Subject: [PATCH 4/4] Readme updated with shortcuts --- README.mkdn => README.md | 32 ++++++++++++++++++-------------- 1 file changed, 18 insertions(+), 14 deletions(-) rename README.mkdn => README.md (79%) diff --git a/README.mkdn b/README.md similarity index 79% rename from README.mkdn rename to README.md index 84b3be5..33bed81 100644 --- a/README.mkdn +++ b/README.md @@ -1,11 +1,20 @@ I just addeded some extra shortcuts. In my system "itunes" is aliased as "i" so ``` - > i p + > i p # alias for 'itunes play' ``` plays a song. Al the credits to the original project! +Some example : + +``` + > i n # alias for 'itunes next' + > i s # alias for 'itunes stop' + > i pls # alias for 'itunes playlists' + # or 'itunes please!' for boring songs :-D +``` + Bash iTunes =========== @@ -17,20 +26,20 @@ Currently it supports the following commands: ``` Navigation commands: - p play Start or resume playing. + p play Resume playing or choose track. pa pause Pause playing. s stop Stop playing. - n next Skip to next track. + n next Skip to next track. pr prev Skip back to previous track. i info View info about current track. - s search Search for tracks. + se search Search for tracks. sh shuffle View or set shuffle status. r repeat View or set repeat status. pl playlist View or choose playlist. pls playlists List all playlists. Volume commands: - v vol[ume] View or adjust iTunes volume 'up', 'down' or percentage. + v vol[ume] View or adjust iTunes volume 'up', 'down' or percentage. m mute Mutes iTunes. um unmute Unmutes iTunes, restoring previous volume level. sv sysvol[ume] View or adjust system volume 'up', 'down' or percentage. @@ -38,15 +47,10 @@ Volume commands: sum sysunmute Unmute system sound. Application commands: - o open Start iTunes running. - q quit Quit iTunes. - sw show Hide the iTunes window. - h hide Show the iTunes window. - -Additional commands: - version Show version information and exit. - help Show this help and exit. - plugins Show a list of plugins installed. + o open Start iTunes running. + q quit Quit iTunes. + sw show Hide the iTunes window. + h hide Show the iTunes window. ``` Setup