All of lore.kernel.org
 help / color / mirror / Atom feed
From: "SZEDER Gábor" <szeder.dev@gmail.com>
To: "Randall S. Becker" <rsbecker@nexbridge.com>
Cc: Jeff King <peff@peff.net>, 'Junio C Hamano' <gitster@pobox.com>,
	git@vger.kernel.org,
	'Linux Kernel' <linux-kernel@vger.kernel.org>,
	git-packagers@googlegroups.com
Subject: Re: [Breakage] Git v2.21.0-rc0 - t5403 (NonStop)
Date: Fri, 8 Feb 2019 12:10:02 +0100	[thread overview]
Message-ID: <20190208111002.GU10587@szeder.dev> (raw)
In-Reply-To: <000d01d4bf9b$d5d48da0$817da8e0$@nexbridge.com>

On Fri, Feb 08, 2019 at 05:48:27AM -0500, Randall S. Becker wrote:
> We have a few new breakages on the NonStop port in 2.21.0-rc0. The first is in t5403, as below:
> 
> /home/git/git/t/trash directory.t5403-post-checkout-hook/clone3/.git/hooks/post-checkout: line 2: $GIT_DIR/post-checkout.args: ambiguous redirect
> not ok 8 - post-checkout hook is triggered by clone
> #
> #               mkdir -p templates/hooks &&
> #               write_script templates/hooks/post-checkout <<-\EOF &&
> #               echo "$@" >$GIT_DIR/post-checkout.args
> #               EOF
> #               git clone --template=templates . clone3 &&
> #               test -f clone3/.git/post-checkout.args
> #
> 
> The post-checkout hook is:
> #!/usr/local/bin/bash
> echo "$@" >$GIT_DIR/post-checkout.args
> 
> This looks like it is a "bash thing" and $GIT_DIR might have to be in quotes, and is not be specific to the platform. If I replace 
> 
> echo "$@" >$GIT_DIR/post-checkout.args
> 
> with
> 
> echo "$@" >"$GIT_DIR/post-checkout.args"
> 
> The test passes.

Wow, this is the second time this "redirection to a filename with
spaces under Bash" issue pops up today, see the other one here:

  https://public-inbox.org/git/20190208031746.22683-2-tmz@pobox.com/T/#u

In short, Bash (when invoked as bash) doesn't conform to POSIX in this
respect; for a (too detailed) explanation see:

  https://public-inbox.org/git/20180926121107.GH27036@localhost/

Even our CodingGuidelines suggest the use of quotes around the
redirection's target.

> I wonder I should provide this patch or whether the author would like to do so.

Well, since you didn't Cc the author, he might very well overlook this
issue, so I think you should ;)


  parent reply	other threads:[~2019-02-08 11:10 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-08 10:48 [Breakage] Git v2.21.0-rc0 - t5403 (NonStop) Randall S. Becker
2019-02-08 10:55 ` Johannes Schindelin
2019-02-08 10:58   ` Randall S. Becker
2019-02-08 11:10 ` SZEDER Gábor [this message]
2019-02-08 11:36   ` Randall S. Becker
2019-02-08 20:11   ` Todd Zullinger
2019-02-08 20:30     ` SZEDER Gábor
2019-02-09  6:48       ` Todd Zullinger

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=20190208111002.GU10587@szeder.dev \
    --to=szeder.dev@gmail.com \
    --cc=git-packagers@googlegroups.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=peff@peff.net \
    --cc=rsbecker@nexbridge.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.