Commit 683ac39e authored by Dennis Gläser's avatar Dennis Gläser
Browse files

[ci] use source branch in upstream mrs

parent 0a66d0ca
Pipeline #7124 passed with stage
......@@ -24,20 +24,19 @@ select tests:
stage: configure
before_script:
- |
if [ ! -d "$DUMUX_FOLDER" ]; then
git clone -b master --depth 1 $DUMUX_REPO $DUMUX_FOLDER
fi
if [[ -n "$DUMUX_MR_SOURCE_BRANCH" ]]; then
echo "Fetching upstream branches related to merge request."
echo "Source branch: $DUMUX_MR_SOURCE_BRANCH"
echo "Target branch: $DUMUX_MR_TARGET_BRANCH"
git clone -b ${DUMUX_MR_SOURCE_BRANCH} --depth 1 $DUMUX_REPO $DUMUX_FOLDER
pushd $DUMUX_FOLDER
git fetch --depth=1 origin ${DUMUX_MR_TARGET_BRANCH}:${DUMUX_MR_TARGET_BRANCH}
popd
else
git clone -b master --depth 1 $DUMUX_REPO $DUMUX_FOLDER
pushd $DUMUX_FOLDER
if [[ -n "$DUMUX_TRIGGER_COMMIT_SHA" ]]; then
echo "Fetching upstream commit $DUMUX_TRIGGER_COMMIT_SHA"
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment