From: Junio C Hamano <gitster@pobox.com>
To: git@vger.kernel.org
Cc: Steven Penny <svnpenn@gmail.com>,
Johannes Sixt <j.sixt@viscovery.net>,
Ramsay Jones <ramsay@ramsay1.demon.co.uk>
Subject: [PATCH 2/2] git-sh-setup: work around Cygwin path handling gotchas
Date: Wed, 16 May 2012 11:00:08 -0700 [thread overview]
Message-ID: <1337191208-21110-3-git-send-email-gitster@pobox.com> (raw)
In-Reply-To: <1337191208-21110-1-git-send-email-gitster@pobox.com>
From: Steven Penny <svnpenn@gmail.com>
From: Steven Penny <svnpenn@gmail.com>
On Cygwin, tools built for Cygwin can take both Windows-style paths
(e.g. C:/dir/file.txt or C:\dir\file.txt) and Cygwin-style paths
(e.g. /cygdrive/c/dir/file.txt), but Windows-native tools can only take
Windows-style paths. Because the paths that are relative to $GIT_DIR,
e.g. the name of the insn sheet file of the "rebase -i" command, are given
to the programs with $GIT_DIR prefixed, and $GIT_DIR in turn is computed
by calling "pwd", wrap "pwd" to call "cygpath -m" to give a Windows-style
path, in a way similar to how mingw does this.
---
git-sh-setup.sh | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/git-sh-setup.sh b/git-sh-setup.sh
index 770a86e..f0f941d 100644
--- a/git-sh-setup.sh
+++ b/git-sh-setup.sh
@@ -241,6 +241,11 @@ case $(uname -s) in
return 1
}
;;
+*CYGWIN*)
+ pwd () {
+ builtin cygpath -m
+ }
+ ;;
*)
is_absolute_path () {
case "$1" in
--
1.7.10.2.537.g0ac6509
next prev parent reply other threads:[~2012-05-16 18:02 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-06 4:24 Git commit path vs rebase path Steven Penny
2012-05-07 17:27 ` Junio C Hamano
2012-05-08 6:22 ` Johannes Sixt
2012-05-08 6:44 ` Steven Penny
2012-05-08 7:06 ` Johannes Sixt
2012-05-08 7:11 ` Steven Penny
2012-05-08 17:02 ` Junio C Hamano
2012-05-08 17:25 ` Junio C Hamano
2012-05-08 22:47 ` Steven Penny
2012-05-09 21:54 ` Junio C Hamano
2012-05-09 23:14 ` Steven Penny
2012-05-10 18:10 ` Ramsay Jones
2012-05-11 4:35 ` Steven Penny
2012-05-13 22:58 ` Ramsay Jones
2012-05-13 23:42 ` Steven Penny
2012-05-14 6:02 ` Johannes Sixt
2012-05-15 17:32 ` Ramsay Jones
2012-05-16 5:52 ` Johannes Sixt
2012-05-17 18:30 ` Ramsay Jones
2012-05-17 19:19 ` Junio C Hamano
2012-05-16 18:00 ` [PATCH 0/2] " Junio C Hamano
2012-05-16 18:00 ` [PATCH 1/2] git-sh-setup: define workaround wrappers before they are used Junio C Hamano
2012-05-17 22:36 ` Ramsay Jones
2012-05-16 18:00 ` Junio C Hamano [this message]
2012-05-16 18:51 ` [PATCH 2/2] git-sh-setup: work around Cygwin path handling gotchas Steven Penny
2012-05-16 19:02 ` Junio C Hamano
2012-05-17 23:15 ` Ramsay Jones
2012-05-18 2:34 ` Junio C Hamano
2012-05-19 0:43 ` Steven Penny
2012-05-21 18:43 ` Ramsay Jones
2012-05-21 22:24 ` Junio C Hamano
2012-05-24 18:27 ` Ramsay Jones
-- strict thread matches above, loose matches on Subject: below --
2012-05-21 23:51 Matt Seitz (matseitz)
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=1337191208-21110-3-git-send-email-gitster@pobox.com \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=j.sixt@viscovery.net \
--cc=ramsay@ramsay1.demon.co.uk \
--cc=svnpenn@gmail.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.
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).