git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Shawn O. Pearce" <spearce@spearce.org>
To: Junio C Hamano <gitster@pobox.com>
Cc: SZEDER GGGbor <szeder@ira.uka.de>,
	Johannes Schindelin <Johannes.Schindelin@gmx.de>,
	Eric Raible <raible@gmail.com>,
	Git Mailing List <git@vger.kernel.org>
Subject: Re: [PATCH] bash: offer only paths after '--'
Date: Tue, 8 Jul 2008 23:18:37 +0000	[thread overview]
Message-ID: <20080708231837.GA16895@spearce.org> (raw)
In-Reply-To: <7vtzf0rusw.fsf@gitster.siamese.dyndns.org>

Junio C Hamano <gitster@pobox.com> wrote:
> SZEDER Gábor <szeder@ira.uka.de> writes:
> 
> > Hope that I got the commit message right (;
> 
> It was very readable.  Thanks.

Acked-by: Shawn O. Pearce <spearce@spearce.org>

> > +__git_has_doubledash ()
> > +{
> > +	local c=1
> > +	while [ $c -lt $COMP_CWORD ]; do
> > +		if [ "--" = "${COMP_WORDS[c]}" ]; then
> > +			return 0
> > +		fi
> > +		c=$((++c))
> 
> This assignment is somewhat curious, although it should work as expected
> either way ;-)

I agree, its damned odd.  But we already do this in the same
sort of loop inside of _git_branch() (see around line 541 in
next).  This new patch is only sticking with our current set
of conventions in the script, so I say its fine.

-- 
Shawn.

  reply	other threads:[~2008-07-08 23:19 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-07 20:41 [PATCH] completion: add branch options --contains --merged --no-merged Eric Raible
2008-07-08  4:49 ` Shawn O. Pearce
2008-07-08  5:30   ` Junio C Hamano
2008-07-08 11:36     ` Johannes Schindelin
2008-07-08 16:56       ` [PATCH] bash: offer only paths after '--' SZEDER Gábor
2008-07-08 17:46         ` Eric Raible
2008-07-08 20:21         ` Junio C Hamano
2008-07-08 23:18           ` Shawn O. Pearce [this message]
2008-07-08 23:23             ` Junio C Hamano
2008-07-08 23:51             ` SZEDER Gábor
2008-07-08 23:55               ` Shawn O. Pearce
2008-07-09  0:06               ` Junio C Hamano

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=20080708231837.GA16895@spearce.org \
    --to=spearce@spearce.org \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=raible@gmail.com \
    --cc=szeder@ira.uka.de \
    /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.
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).