* [PATCH] t5510: Do not use $(pwd) when fetching / pushing / pulling via rsync
@ 2014-03-19 19:43 Sebastian Schuberth
2014-03-19 20:03 ` Johannes Schindelin
0 siblings, 1 reply; 3+ messages in thread
From: Sebastian Schuberth @ 2014-03-19 19:43 UTC (permalink / raw)
To: git; +Cc: Johannes Schindelin, Johannes Sixt, thomas.braun
On MINGW, "pwd" is defined as "pwd -W" in test-lib.sh. This usually is the
right thing, but the absolute Windows path with a colon confuses rsync. We
could use $PWD in this case to work around the issue, but in fact there is
no need to use an absolute path in the first place, so get rid of it.
This was discovered in the context of the mingwGitDevEnv project and only
did not surface before with msysgit because the latter does not ship
rsync.
Signed-off-by: Sebastian Schuberth <sschuberth@gmail.com>
---
t/t5510-fetch.sh | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/t/t5510-fetch.sh b/t/t5510-fetch.sh
index ab28594..5acd753 100755
--- a/t/t5510-fetch.sh
+++ b/t/t5510-fetch.sh
@@ -301,7 +301,7 @@ test_expect_success 'fetch via rsync' '
mkdir rsynced &&
(cd rsynced &&
git init --bare &&
- git fetch "rsync:$(pwd)/../.git" master:refs/heads/master &&
+ git fetch "rsync:../.git" master:refs/heads/master &&
git gc --prune &&
test $(git rev-parse master) = $(cd .. && git rev-parse master) &&
git fsck --full)
@@ -312,7 +312,7 @@ test_expect_success 'push via rsync' '
(cd rsynced2 &&
git init) &&
(cd rsynced &&
- git push "rsync:$(pwd)/../rsynced2/.git" master) &&
+ git push "rsync:../rsynced2/.git" master) &&
(cd rsynced2 &&
git gc --prune &&
test $(git rev-parse master) = $(cd .. && git rev-parse master) &&
@@ -323,7 +323,7 @@ test_expect_success 'push via rsync' '
mkdir rsynced3 &&
(cd rsynced3 &&
git init) &&
- git push --all "rsync:$(pwd)/rsynced3/.git" &&
+ git push --all "rsync:rsynced3/.git" &&
(cd rsynced3 &&
test $(git rev-parse master) = $(cd .. && git rev-parse master) &&
git fsck --full)
--
1.8.5.2.msysgit.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] t5510: Do not use $(pwd) when fetching / pushing / pulling via rsync
2014-03-19 19:43 [PATCH] t5510: Do not use $(pwd) when fetching / pushing / pulling via rsync Sebastian Schuberth
@ 2014-03-19 20:03 ` Johannes Schindelin
2014-03-19 21:10 ` Junio C Hamano
0 siblings, 1 reply; 3+ messages in thread
From: Johannes Schindelin @ 2014-03-19 20:03 UTC (permalink / raw)
To: Sebastian Schuberth; +Cc: Junio C Hamano, Johannes Sixt, thomas.braun, git
Hi Sebastian,
On Wed, 19 Mar 2014, Sebastian Schuberth wrote:
> On MINGW, "pwd" is defined as "pwd -W" in test-lib.sh. This usually is the
> right thing, but the absolute Windows path with a colon confuses rsync. We
> could use $PWD in this case to work around the issue, but in fact there is
> no need to use an absolute path in the first place, so get rid of it.
>
> This was discovered in the context of the mingwGitDevEnv project and only
> did not surface before with msysgit because the latter does not ship
> rsync.
ACK
Ciao,
Dscho
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] t5510: Do not use $(pwd) when fetching / pushing / pulling via rsync
2014-03-19 20:03 ` Johannes Schindelin
@ 2014-03-19 21:10 ` Junio C Hamano
0 siblings, 0 replies; 3+ messages in thread
From: Junio C Hamano @ 2014-03-19 21:10 UTC (permalink / raw)
To: Johannes Schindelin; +Cc: Sebastian Schuberth, Johannes Sixt, thomas.braun, git
Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
> Hi Sebastian,
>
> On Wed, 19 Mar 2014, Sebastian Schuberth wrote:
>
>> On MINGW, "pwd" is defined as "pwd -W" in test-lib.sh. This usually is the
>> right thing, but the absolute Windows path with a colon confuses rsync. We
>> could use $PWD in this case to work around the issue, but in fact there is
>> no need to use an absolute path in the first place, so get rid of it.
>>
>> This was discovered in the context of the mingwGitDevEnv project and only
>> did not surface before with msysgit because the latter does not ship
>> rsync.
>
> ACK
>
> Ciao,
> Dscho
Thanks.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2014-03-19 21:11 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-19 19:43 [PATCH] t5510: Do not use $(pwd) when fetching / pushing / pulling via rsync Sebastian Schuberth
2014-03-19 20:03 ` Johannes Schindelin
2014-03-19 21:10 ` Junio C Hamano
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.