Skip to content

Commit

Permalink
cicd: Fix calculating opencga branch in pull request approve workflow…
Browse files Browse the repository at this point in the history
… #TASK-6981
  • Loading branch information
juanfeSanahuja committed Oct 2, 2024
1 parent 8044850 commit 09241e0
Showing 1 changed file with 11 additions and 6 deletions.
17 changes: 11 additions & 6 deletions .github/workflows/test-xetabase-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,13 +51,18 @@ jobs:
path: opencga-enterprise
fetch-depth: "10"
- id: get_opencga_branch
name: Get OpenCGA branch from 'pom.xml' property
name: Get OpenCGA branch
run: |
pwd
ls -lrtha
ls -lrtha ./opencga-enterprise
chmod +x ./opencga-enterprise/.github/workflows/scripts/get-opencga-xetabase-branch.sh
opencga_branch=$(./opencga-enterprise/.github/workflows/scripts/get-opencga-xetabase-branch.sh)
# If the task exists in the opencga repository, this is the branch to be tested
if [[ "${{ inputs.task }}" == TASK* ]]; then
if [ "$(git ls-remote "https://github.com/opencb/opencga.git" "${{ inputs.task }}" ] ; then
opencga_branch="${{ inputs.task }}";
return 0;
fi
else
chmod +x ./opencga-enterprise/.github/workflows/scripts/get-opencga-xetabase-branch.sh
opencga_branch=$(./opencga-enterprise/.github/workflows/scripts/get-opencga-xetabase-branch.sh)
fi
echo "opencga_branch=${opencga_branch}"
echo "opencga_branch=${opencga_branch}" >> $GITHUB_OUTPUT
- name: Clone OpenCGA branch '${{ steps.get_opencga_branch.outputs.opencga_branch }}'
Expand Down

0 comments on commit 09241e0

Please sign in to comment.