Re: [PATCH 2/4] t0021: put $TEST_ROOT in $PATH
- From
Jeff King <peff@peff.net>
- Date
- Nov 3, 2016, 20:44 UTC
- Message-ID
- <20161103204438.zfe653c2bsv3zqkx@sigill.intra.peff.net>
- In-Reply-To
- <d36d8b51-f2d7-a2f5-89ea-369f49556e10@kdbg.org>
On Thu, Nov 03, 2016 at 09:40:01PM +0100, Johannes Sixt wrote:
Show 12 quoted lines
> > TEST_ROOT="$(pwd)" > > +PATH=$TEST_ROOT:$PATH > > This causes problems on Windows. We need the following squashed in. > > ---- 8< ---- > [PATCH] squash! t0021: put $TEST_ROOT in $PATH > > 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.)
Thanks. I have to admit I remain confused about which one to use at any given invocation (I would have thought that switching to $PWD causes problems elsewhere in the script, but I guess file redirection is capable of handling either type).
-Peff