Merge branch 'bw/submodule-sed-solaris' into maint

By Ben Walton
* bw/submodule-sed-solaris:
  Avoid bug in Solaris xpg4/sed as used in submodule
maint
Junio C Hamano 2012-05-10 10:27:58 -07:00
commit c83645a642
1 changed files with 3 additions and 2 deletions

View File

@ -167,10 +167,11 @@ module_clone()
a=${a%/} a=${a%/}
b=${b%/} b=${b%/}


rel=$(echo $b | sed -e 's|[^/]*|..|g') # Turn each leading "*/" component into "../"
rel=$(echo $b | sed -e 's|[^/][^/]*|..|g')
echo "gitdir: $rel/$a" >"$path/.git" echo "gitdir: $rel/$a" >"$path/.git"


rel=$(echo $a | sed -e 's|[^/]*|..|g') rel=$(echo $a | sed -e 's|[^/][^/]*|..|g')
(clear_local_git_env; cd "$path" && GIT_WORK_TREE=. git config core.worktree "$rel/$b") (clear_local_git_env; cd "$path" && GIT_WORK_TREE=. git config core.worktree "$rel/$b")
} }