.github/workflows: compare PR branch to master

Since 4410de52c1 we fetch all origin branches, and FETCH_HEAD can point
elsewhere
This commit is contained in:
Piotr Wójcik 2023-01-10 22:00:00 +01:00 committed by classabbyamp
parent c051a0d189
commit f5a960da8f
1 changed files with 1 additions and 1 deletions

View File

@ -10,7 +10,7 @@ case "$tip" in
*) tip="${tip%% *}" ;;
esac
base="$(git merge-base FETCH_HEAD "$tip")"
base="$(git merge-base origin/HEAD "$tip")"
[ $(git rev-list --count "$tip" "^$base") -lt 200 ] || {
echo "::error title=Branch out of date::Your branch is too out of date. Please rebase on upstream and force-push."