zsh-workers
 help / color / mirror / code / Atom feed
From: Clint Adams <clint@zsh.org>
To: zsh-workers@sunsite.dk
Subject: PATCH: _mpc update
Date: Wed, 24 May 2006 23:55:39 -0400	[thread overview]
Message-ID: <20060525035539.GA1551@scowler.net> (raw)

Another patch from R.Ramkumar.

Index: Completion/Unix/Command/_mpc
===================================================================
RCS file: /cvsroot/zsh/zsh/Completion/Unix/Command/_mpc,v
retrieving revision 1.2
diff -u -r1.2 _mpc
--- Completion/Unix/Command/_mpc	26 Apr 2006 04:37:52 -0000	1.2
+++ Completion/Unix/Command/_mpc	25 May 2006 03:54:54 -0000
@@ -26,14 +26,19 @@
 
   mpc_cmds=(
     add:"add a song to the current playlist"
+    crop:"remove all songs except for the currently playing song"
     del:"remove a song from the current playlist"
     play:"start playing"
     next:"play the next song in the current playlist"
     prev:"play the previous song in the current playlist"
     pause:"pause the currently playing song"
+    toggle:"toggles Play/Pause, plays if stopped"
     stop:"stop the currently playing playlists"
     seek:"seek to the position specified in percent"
     clear:"clear the current playlist"
+    outputs:"show the current outputs"
+    enable:"enable a output"
+    disable:"disable a output"
     shuffle:"shuffle the current playlist"
     move:"move song in playlist"
     playlist:"print the current playlist"
@@ -49,7 +54,9 @@
     search:"search for a song"
     crossfade:"set and display crossfade settings"
     update:"scan music directory for updates"
+    stats:"display statistics about MPD"
     version:"report version of MPD"
+    status:"display MPD status"
   )
 
   if (( CURRENT == 1 )); then
@@ -154,6 +161,13 @@
   fi
 }
 
+(( $+functions[_mpc_helper_outputs] )) ||
+_mpc_helper_outputs() {
+  local vals outline
+  vals=(${${${${(M)${(f)"$(mpc outputs 2> /dev/null)"}:#Output * \(*\) is (en|dis)abled}##Output }%%\) is (en|dis)abled}/ \(/:})
+  _describe -t outputs output vals
+}
+
 _mpc_add() {
   _mpc_helper_files
 }
@@ -170,6 +184,14 @@
   _message "floating point percent value"
 }
 
+_mpc_enable() {
+  _mpc_helper_outputs
+}
+
+_mpc_disable() {
+  _mpc_helper_outputs
+}
+
 _mpc_move() {
   if (( $#words <= 3 )); then
     _mpc_helper_songnumbers


                 reply	other threads:[~2006-05-25  3:55 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20060525035539.GA1551@scowler.net \
    --to=clint@zsh.org \
    --cc=zsh-workers@sunsite.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).