From 02586d385ed48a057e74a4170008b641f17d6bd9 Mon Sep 17 00:00:00 2001 From: Eesaan Atluri <atlurie@uab.edu> Date: Fri, 8 Nov 2024 16:20:30 -0600 Subject: [PATCH] feat: Define src and target branch using vars This will let you define the branch name for the PR you want to test from the src repo and target branch to merge into, in the target repo --- .gitlab-ci.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index d5a4b3e..10c64ca 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -52,15 +52,15 @@ workflow: - cd CRI_XCBC - git config user.name "${GIT_AUTHOR_NAME}" - git config user.email "${GIT_AUTHOR_EMAIL}" - - git fetch origin uab-prod - - git fetch upstream dev - - git checkout uab-prod - - git merge origin/uab-prod + - git checkout ${EXT_PR_TARGET_BRANCH} + - git fetch origin ${EXT_PR_TARGET_BRANCH} + - git merge origin/${EXT_PR_TARGET_BRANCH} - git checkout -b integration - - git merge upstream/dev - export CRI_XCBC_HEAD=$(git rev-parse --short HEAD) - export CRI_XCBC_dev=$(git rev-parse --short upstream/dev) - export CRI_XCBC_prod=$(git rev-parse --short origin/uab-prod) + - git fetch upstream ${EXT_PR_SRC_BRANCH} + - git merge upstream/${EXT_PR_SRC_BRANCH} - cd .. - export PACKER_IMAGE_HEAD=$(git rev-parse --short HEAD) - echo CRI_XCBC_HEAD=${CRI_XCBC_HEAD} | tee -a $CI_PROJECT_DIR/image.env -- GitLab