git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Jeff King <peff@peff.net>
To: Johannes Sixt <j6t@kdbg.org>
Cc: Junio C Hamano <gitster@pobox.com>,
	Johannes Schindelin <johannes.schindelin@gmx.de>,
	git@vger.kernel.org
Subject: Re: [PATCH] t0021, t5615: use $PWD instead of $(pwd) in PATH-like shell variables
Date: Fri, 11 Nov 2016 13:16:59 -0500	[thread overview]
Message-ID: <20161111181658.bwclcxedsrs4wcu6@sigill.intra.peff.net> (raw)
In-Reply-To: <2b69d098-92ef-77b0-367a-516e9edbe257@kdbg.org>

On Fri, Nov 11, 2016 at 06:31:48PM +0100, Johannes Sixt wrote:

> We have to use $PWD instead of $(pwd) because on Windows the latter
> would add a C: style path to bash's Unix-style $PATH variable, which
> becomes confused by the colon after the drive letter. ($PWD is a
> Unix-style path.)
> 
> In the case of GIT_ALTERNATE_OBJECT_DIRECTORIES, bash on Windows
> assembles a Unix-style path list with the colon as separators. It
> converts the value to a Windows-style path list with the semicolon as
> path separator when it forwards the variable to git.exe. The same
> confusion happens when bash's original value is contaminated with
> Windows style paths.

So on reading your original I wondered why you did not need to use the
";", and that explains it. But wow, it's subtle.

I don't know what people typically write in the wild, and if it's worth
actually testing explicitly the ";" case. I'll leave that to Windows
people to debate.

-Peff

  reply	other threads:[~2016-11-11 18:18 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-11 16:29 [PATCH] mingw: hot-fix t5615 Johannes Schindelin
2016-11-11 17:06 ` Junio C Hamano
2016-11-11 17:11   ` Johannes Sixt
2016-11-11 17:31     ` [PATCH] t0021, t5615: use $PWD instead of $(pwd) in PATH-like shell variables Johannes Sixt
2016-11-11 18:16       ` Jeff King [this message]
2016-11-11 18:55       ` Junio C Hamano
2016-11-12 11:40         ` Johannes Schindelin
2016-11-13  1:13           ` Junio C Hamano
2016-11-14  9:11             ` Lars Schneider
2016-11-14 16:35               ` Torsten Bögershausen
2016-11-14 17:01                 ` Jeff King
2016-11-14 19:45                   ` Ramsay Jones
2016-11-14 17:21               ` Junio C Hamano
2016-11-15 16:54                 ` Johannes Schindelin
2016-11-16  9:47                   ` Johannes Schindelin
2016-11-16 21:51                     ` Junio C Hamano
2016-11-11 18:12 ` [PATCH] mingw: hot-fix t5615 Jeff King

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

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20161111181658.bwclcxedsrs4wcu6@sigill.intra.peff.net \
    --to=peff@peff.net \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=j6t@kdbg.org \
    --cc=johannes.schindelin@gmx.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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).