Resolve "fatal: couldn't find remote ref xxx/master"

This commit is contained in:
proletarius101 2023-10-01 16:40:16 +00:00 committed by linsui
parent f74ee55d7c
commit e5952c4958

View file

@ -52,8 +52,8 @@ variables:
export SOURCE_REF="${CI_COMMIT_SHA}"
else
git remote add upstream https://gitlab.com/fdroid/fdroiddata.git || true
git fetch upstream ${CI_DEFAULT_BRANCH}
export TARGET_REF=$(git merge-base HEAD upstream/${CI_DEFAULT_BRANCH})
git fetch upstream ${CI_MERGE_REQUEST_TARGET_BRANCH_NAME:-master}
export TARGET_REF=$(git merge-base HEAD upstream/${CI_MERGE_REQUEST_TARGET_BRANCH_NAME:-master})
export SOURCE_REF="${CI_COMMIT_SHA}"
fi;