mirror of
https://github.com/git/git.git
synced 2026-02-07 08:15:23 +00:00
Merge 'normalize-win-paths' into HEAD
This commit is contained in:
@@ -306,10 +306,8 @@ case $(uname -s) in
|
||||
find () {
|
||||
/usr/bin/find "$@"
|
||||
}
|
||||
# git sees Windows-style pwd
|
||||
pwd () {
|
||||
builtin pwd -W
|
||||
}
|
||||
# Let pwd always return the uniqe real windows path
|
||||
alias pwd='pwd -W'
|
||||
is_absolute_path () {
|
||||
case "$1" in
|
||||
[/\\]* | [A-Za-z]:*)
|
||||
|
||||
@@ -285,9 +285,6 @@ module_clone()
|
||||
# resolve any symlinks that might be present in $PWD
|
||||
a=$(cd_to_toplevel && cd "$gitdir" && pwd)/
|
||||
b=$(cd_to_toplevel && cd "$sm_path" && pwd)/
|
||||
# normalize Windows-style absolute paths to POSIX-style absolute paths
|
||||
case $a in [a-zA-Z]:/*) a=/${a%%:*}${a#*:} ;; esac
|
||||
case $b in [a-zA-Z]:/*) b=/${b%%:*}${b#*:} ;; esac
|
||||
# Remove all common leading directories after a sanity check
|
||||
if test "${a#$b}" != "$a" || test "${b#$a}" != "$b"; then
|
||||
die "$(eval_gettext "Gitdir '\$a' is part of the submodule path '\$b' or vice versa")"
|
||||
|
||||
Reference in New Issue
Block a user