git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Pavel Roskin <proski@gnu.org>
To: Junio C Hamano <junkio@cox.net>
Cc: git@vger.kernel.org
Subject: Re: [PATCH 1/3] cg-mv doesn't work with bash 3.1.7 due to excessive quotes
Date: Fri, 03 Mar 2006 09:11:07 -0500	[thread overview]
Message-ID: <1141395067.30343.14.camel@dv> (raw)
In-Reply-To: <7vbqwo3xo4.fsf@assigned-by-dhcp.cox.net>

On Thu, 2006-03-02 at 21:27 -0800, Junio C Hamano wrote:
> Pavel Roskin <proski@gnu.org> writes:
> 
> > -	ARGS2["${#ARGS2[@]}"]="$_git_relpath${arg%/}"
> > +	ARGS2[${#ARGS2[@]}]="$_git_relpath${arg%/}"
> 
> Is this an application bug?  It looks like a workaround for a
> bug in the shell...

Indeed, bash 3.00.16 (FC4) is fine with the original cg-mv.  On the
other hand, bash 3.1.7 (FC development) doesn't even like this:

$ arg["0"]=0
bash: "0": syntax error: operand expected (error token is ""0"")

I don't see any relevant information in the NEWS file, so even if it's
no a bug, it's an undocumented feature :-)

Anyway, the quotes are excessive, bash is (sort of) correct to complain
about it, and I don't see any other instances of quoting array arguments
in cogito.

The quotes in question have always existed in cg-mv, they were not added
to work around anything.

-- 
Regards,
Pavel Roskin

  reply	other threads:[~2006-03-03 14:11 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-03-03  1:11 [PATCH 1/3] cg-mv doesn't work with bash 3.1.7 due to excessive quotes Pavel Roskin
2006-03-03  1:11 ` [PATCH 2/3] Make tutorial-script work with current cogito Pavel Roskin
2006-03-19 22:37   ` Petr Baudis
2006-03-03  1:11 ` [PATCH 3/3] Allow the tutorial script to be run by "make test" Pavel Roskin
2006-03-03  5:27 ` [PATCH 1/3] cg-mv doesn't work with bash 3.1.7 due to excessive quotes Junio C Hamano
2006-03-03 14:11   ` Pavel Roskin [this message]
2006-03-10 20:48     ` Pavel Roskin
2006-03-03 16:34   ` Josef Weidendorfer

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=1141395067.30343.14.camel@dv \
    --to=proski@gnu.org \
    --cc=git@vger.kernel.org \
    --cc=junkio@cox.net \
    /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).