From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17321 invoked from network); 10 Sep 2008 22:20:35 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.2.5 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 10 Sep 2008 22:20:35 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 52136 invoked from network); 10 Sep 2008 22:20:18 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 10 Sep 2008 22:20:18 -0000 Received: (qmail 19141 invoked by alias); 10 Sep 2008 22:20:08 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 25640 Received: (qmail 19121 invoked from network); 10 Sep 2008 22:20:06 -0000 Received: from bifrost.dotsrc.org (130.225.254.106) by sunsite.dk with SMTP; 10 Sep 2008 22:20:06 -0000 Received: from smtprelay08.ispgateway.de (smtprelay08.ispgateway.de [80.67.29.8]) by bifrost.dotsrc.org (Postfix) with ESMTP id 29E4D802710B for ; Thu, 11 Sep 2008 00:20:03 +0200 (CEST) Received: from [212.117.84.216] (helo=fsst.voodoo.lan) by smtprelay08.ispgateway.de with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.68) (envelope-from ) id 1KdY2d-0004ro-A6 for zsh-workers@sunsite.dk; Thu, 11 Sep 2008 00:20:03 +0200 Received: from hawk by fsst.voodoo.lan with local (Exim 4.69) (envelope-from ) id 1KdY2c-0001d9-1E for zsh-workers@sunsite.dk; Thu, 11 Sep 2008 00:20:02 +0200 Date: Thu, 11 Sep 2008 00:20:01 +0200 From: Frank Terbeck To: zsh workers Subject: PATCH: yet another fix for alias handling in _git Message-ID: <20080910222001.GA2182@fsst.voodoo.lan> Mail-Followup-To: zsh workers MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) X-Df-Sender: 430444 X-Virus-Scanned: ClamAV 0.92.1/8212/Wed Sep 10 22:19:49 2008 on bifrost X-Virus-Status: Clean An empty word only needs to be added to $tmpwords[] if there was an empty word at the end of $words[] in the first place. Index: Completion/Unix/Command/_git =================================================================== RCS file: /cvsroot/zsh/zsh/Completion/Unix/Command/_git,v retrieving revision 1.102 diff -u -r1.102 _git --- Completion/Unix/Command/_git 7 Sep 2008 16:52:28 -0000 1.102 +++ Completion/Unix/Command/_git 10 Sep 2008 22:19:11 -0000 @@ -4286,7 +4286,7 @@ if [[ -n "${words[3,-1]}" ]] ; then tmpwords+=(${words[3,-1]}) fi - tmpwords+=('') + [[ -n ${words[$CURRENT]} ]] || tmpwords+=('') (( CURRENT += ${#expalias} - 1 )) words=("${tmpwords[@]}") unset tmpwords expalias