From: Shawn O. Pearce Date: Fri, 21 Sep 2007 15:08:50 +0000 (-0400) Subject: git-gui: Handle starting on mapped shares under Cygwin X-Git-Tag: gitgui-0.8.4~7 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=299077fb40eac1e128b7bc09d5d992960e6f11c2;p=git.git git-gui: Handle starting on mapped shares under Cygwin I really cannot explain Cygwin's behavior here but if we start git-gui through Cygwin on a local drive it appears that Cygwin is leaving $env(PATH) in Unix style, even if it started a native (non-Cygwin) Tcl/Tk process to run git-gui. Yet starting that same git-gui and Tcl/Tk combination through Cygwin on a network share causes it to automatically convert $env(PATH) into Windows style, which broke our internal "which" implementation. Signed-off-by: Shawn O. Pearce --- diff --git a/git-gui.sh b/git-gui.sh index 10710e26c..62e165227 100755 --- a/git-gui.sh +++ b/git-gui.sh @@ -305,7 +305,7 @@ proc _which {what} { global env _search_exe _search_path if {$_search_path eq {}} { - if {[is_Cygwin]} { + if {[is_Cygwin] && [regexp {^(/|\.:)} $env(PATH)]} { set _search_path [split [exec cygpath \ --windows \ --path \