From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25427 invoked from network); 25 Sep 2004 00:38:29 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 25 Sep 2004 00:38:29 -0000 Received: (qmail 95397 invoked from network); 25 Sep 2004 00:38:23 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 25 Sep 2004 00:38:23 -0000 Received: (qmail 11588 invoked by alias); 25 Sep 2004 00:38:20 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 20409 Received: (qmail 11573 invoked from network); 25 Sep 2004 00:38:19 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 25 Sep 2004 00:38:19 -0000 Received: (qmail 95123 invoked from network); 25 Sep 2004 00:38:19 -0000 Received: from dsl3-63-249-88-2.cruzio.com (HELO binome.blorf.net) (63.249.88.2) by a.mx.sunsite.dk with SMTP; 25 Sep 2004 00:38:17 -0000 Received: by binome.blorf.net (Postfix, from userid 1000) id E615B9C40; Fri, 24 Sep 2004 17:38:15 -0700 (PDT) Date: Fri, 24 Sep 2004 17:38:15 -0700 From: Wayne Davison To: zsh-workers@sunsite.dk Subject: Completion for darcs Message-ID: <20040925003815.GD26071@blorf.net> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="zhXaljGHf11kAtnf" Content-Disposition: inline User-Agent: Mutt/1.5.6+20040722i X-Spam-Checker-Version: SpamAssassin 2.63 on a.mx.sunsite.dk X-Spam-Level: X-Spam-Status: No, hits=-1.4 required=6.0 tests=BAYES_20 autolearn=no version=2.63 X-Spam-Hits: -1.4 --zhXaljGHf11kAtnf Content-Type: text/plain; charset=us-ascii Content-Disposition: inline I've made some simple changes to the zsh-completion example that ships with darcs (the version control system) and checked it into the Completion/Unix/Command dir. It seems to work well in my testing so far. I've attached the file to this email as well. ..wayne.. --zhXaljGHf11kAtnf Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename=_darcs #compdef darcs _darcs() { # 1 based array if (($CURRENT == 2)); then compadd -- $( darcs --commands | grep "^$PREFIX" ) return 0 fi compadd -- $( darcs ${words[2]} --list-option | grep "^$PREFIX" ) return 0 } _darcs "$@" --zhXaljGHf11kAtnf--