Skip to content

Commit a8ee932

Browse files
committed
please.sh update msys2-runtime: avoid using alternates
When using an alternate in `src/msys2-runtime/` pointing to an absolute path, there is always the problem that either /usr/bin/git or /mingw64/bin/git will be unhappy. So let's just dissociate `src/msys2-runtime/` instead. Signed-off-by: Johannes Schindelin <[email protected]>
1 parent beb6558 commit a8ee932

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

please.sh

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2694,6 +2694,15 @@ upgrade () { # [--directory=<artifacts-directory>] [--only-mingw] [--no-build] [
26942694
cd src/msys2-runtime ||
26952695
die "Invalid worktree for '%s'\n" "$package"
26962696

2697+
case "$(test -x /usr/bin/git && cat .git/objects/info/alternates 2>/dev/null)" in
2698+
/*)
2699+
echo "dissociating worktree, to allow MINGW Git to access the worktree" >&2 &&
2700+
/usr/bin/git repack -ad &&
2701+
rm .git/objects/info/alternates ||
2702+
die "Could not dissociate src/msys2-runtime\n"
2703+
;;
2704+
esac
2705+
26972706
require_remote cygwin \
26982707
git://sourceware.org/git/newlib-cygwin.git &&
26992708
git fetch --tags cygwin &&

0 commit comments

Comments
 (0)