From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23960 invoked from network); 1 Oct 2007 07:17:12 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00 autolearn=ham version=3.2.3 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 1 Oct 2007 07:17:12 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 16932 invoked from network); 1 Oct 2007 07:17:05 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 1 Oct 2007 07:17:05 -0000 Received: (qmail 22194 invoked by alias); 1 Oct 2007 07:17:03 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 23879 Received: (qmail 22181 invoked from network); 1 Oct 2007 07:17:02 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 1 Oct 2007 07:17:02 -0000 Received: (qmail 16688 invoked from network); 1 Oct 2007 07:17:02 -0000 Received: from an-out-0708.google.com (209.85.132.248) by a.mx.sunsite.dk with SMTP; 1 Oct 2007 07:16:56 -0000 Received: by an-out-0708.google.com with SMTP id c14so750424anc for ; Mon, 01 Oct 2007 00:16:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:sender:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references:x-google-sender-auth; bh=sh2uq8/K63opb2ijXa5PjWKiyispSGXP1dkIIlnZ+sA=; b=jwAerwqszrn3MsLUVuPfuN7i6uxdMxl2mS8MxlbFBR/mg/1Ug/QQrCVh5Fh6A4Xo9pVlFISp5r1cbdRDdXYo/sycG2l8U98qq3Fe+O/e55zQ1kPpSRx0xJJfXrAiPXDDlAagiRar6aFNpw9caCp9YnfSD0iXoj3KP41S+S53N+M= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:sender:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references:x-google-sender-auth; b=opNf5mKYvbkSyDJEw4QwsKaFnP1BsEta8F7LnI9/rR3Yv17tnlskdG5sdoRsHSlULTSdYlGxbQAs2f0GgdhvDVbFeOv37IictZUY7TonFYpCj0cnRawQctoqbbEyL9ZjTj4geLuvYPplDbICHP0xmoqP7SXHL44ZUu6tjuLpA5E= Received: by 10.90.25.3 with SMTP id 3mr988158agy.1191223014710; Mon, 01 Oct 2007 00:16:54 -0700 (PDT) Received: by 10.90.93.19 with HTTP; Mon, 1 Oct 2007 00:16:54 -0700 (PDT) Message-ID: Date: Mon, 1 Oct 2007 09:16:54 +0200 From: "Nikolai Weibull" Sender: nikolai.weibull@gmail.com To: zsh-workers@sunsite.dk Subject: Re: PATCH: _git log arguments In-Reply-To: <20070930194014.GA18558@scowler.net> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20070930194014.GA18558@scowler.net> X-Google-Sender-Auth: e310d8e028a929a2 On 9/30/07, Clint Adams wrote: > I tried this with various things that called git-ls-files but > they were insanely slow. > - $revision_arguments && ret=0 > + "$revision_arguments[@]" \ Why use "$revision_arguments[@]"? $revision_arguments works just as good and you don't need all the quoting and expansion fluff. I see this style has been used for $merge_args as well, even though most of the file doesn't. > + '*:tree-ish: _alternative c\:\:__git_committishs f\:\:_files' && ret=0 I don't like this at all. Why not simply use __git_cached_files? And if we really need __git_committishs, let's at least use a separate function for that with proper descriptions and tags. Index: Completion/Unix/Command/_git =================================================================== RCS file: /cvsroot/zsh/zsh/Completion/Unix/Command/_git,v retrieving revision 1.33 diff -u -r1.33 _git --- Completion/Unix/Command/_git 30 Sep 2007 18:18:18 -0000 1.33 +++ Completion/Unix/Command/_git 1 Oct 2007 07:15:31 -0000 @@ -1711,7 +1711,8 @@ __git_setup_revision_arguments _arguments -S \ - $revision_arguments && ret=0 + $revision_arguments \ + '*:file:__git_cached_files' && ret=0 } # TODO: repository needs fixing nikolai