Skip to content

Commit 6b53f7c

Browse files
committed
please.sh: drop obsolete require_git_src_dir function
This was used in the release process that has migrated completely to git-for-windows-automation, and in the Coverity stuff (which has moved to upstream Git anyway). Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
1 parent 48908de commit 6b53f7c

File tree

1 file changed

+0
-76
lines changed

1 file changed

+0
-76
lines changed

please.sh

Lines changed: 0 additions & 76 deletions
Original file line numberDiff line numberDiff line change
@@ -159,25 +159,6 @@ require_clean_worktree () {
159159
die "%s not up-to-date\n" "$sdk$pkgpath"
160160
}
161161

162-
ff_main_branch () {
163-
case "$(git rev-parse --symbolic-full-name HEAD)" in
164-
refs/heads/main) ;; # okay
165-
refs/heads/master)
166-
git branch -m main ||
167-
die "%s: could not rename the main branch\n" "$sdk$pkgpath"
168-
;;
169-
*)
170-
die "%s: Not on 'main'\n" "$sdk$pkgpath"
171-
;;
172-
esac
173-
174-
require_clean_worktree
175-
176-
git pull --ff-only origin HEAD ||
177-
test 0 -eq $(git rev-list --count ..FETCH_HEAD) ||
178-
die "%s: cannot fast-forward main branch\n" "$sdk$pkgpath"
179-
}
180-
181162
fast_forward () {
182163
if test -d "$2"/.git
183164
then
@@ -241,63 +222,6 @@ ensure_valid_login_shell () {
241222
esac' >&2
242223
}
243224

244-
require_git_src_dir () {
245-
sdk="$sdk64"
246-
if test ! -d "$git_src_dir"
247-
then
248-
if test ! -d "${git_src_dir%/src/git}"
249-
then
250-
mingw_packages_dir="${git_src_dir%/*/src/git}"
251-
if test ! -d "$mingw_packages_dir"
252-
then
253-
case "$mingw_packages_dir" in
254-
*/MINGW-packages)
255-
o=https://github.com/git-for-windows &&
256-
git -C "${mingw_packages_dir%/*}" \
257-
clone $o/MINGW-packages ||
258-
die "Could not clone into %s\n" \
259-
"$mingw_packages_dir"
260-
;;
261-
*)
262-
die "Do not know how to clone %s\n" \
263-
"$mingw_packages_dir"
264-
;;
265-
esac
266-
else
267-
git -C "$mingw_packages_dir" fetch &&
268-
git -C "$mingw_packages_dir" \
269-
checkout -t origin/main ||
270-
die "Could not check out %s\n" \
271-
"$mingw_packages_dir"
272-
fi
273-
fi
274-
(cd "${git_src_dir%/src/git}" &&
275-
echo "Checking out Git (not making it)" >&2 &&
276-
"$sdk64/git-cmd" --command=usr\\bin\\sh.exe -l -c \
277-
'makepkg-mingw --noconfirm -s -o' &&
278-
case "$(test -x /usr/bin/git && cat src/git/.git/objects/info/alternates 2>/dev/null)" in
279-
/*)
280-
echo "Dissociating worktree, to allow MINGW git to access the worktree" >&2 &&
281-
/usr/bin/git -C src/git/ repack -ad &&
282-
rm src/git/.git/objects/info/alternates
283-
;;
284-
esac) ||
285-
die "Could not initialize %s\n" "$git_src_dir"
286-
fi
287-
288-
test ! -f "$git_src_dir/PKGBUILD" ||
289-
(cd "$git_src_dir/../.." &&
290-
sdk= pkgpath=$PWD ff_main_branch) ||
291-
die "MINGW-packages not up-to-date\n"
292-
293-
test false = "$(git -C "$git_src_dir" config core.autoCRLF)" ||
294-
(cd "$git_src_dir" &&
295-
git config core.autoCRLF false &&
296-
rm .git/index
297-
git reset --hard) ||
298-
die "Could not make sure Git sources are checked out LF-only\n"
299-
}
300-
301225
# build_and_test_64; intended to build and test 64-bit Git in MINGW-packages
302226
build_and_test_64 () {
303227
skip_tests=

0 commit comments

Comments
 (0)