Re: [PATCH] bash: offer only paths after '--'
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jul 8, 2008, 20:21 UTC
- Message-ID
- <7vtzf0rusw.fsf@gitster.siamese.dyndns.org>
- In-Reply-To
- <20080708165614.GB8224@neumann>
SZEDER Gábor <szeder@ira.uka.de> writes:
> Hope that I got the commit message right (;
It was very readable. Thanks.
Show 8 quoted lines
> +__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 ;-)
Shawn?