From 109fd1753b1781cbb90e6521ac6c28d186ae187f Mon Sep 17 00:00:00 2001 From: MonsterDruide1 <5958456@gmail.com> Date: Tue, 27 Feb 2024 21:51:57 +0100 Subject: [PATCH] Attempts to fix some issues with workflow --- .github/workflows/clean-headers.yml | 5 ++++- .github/workflows/copy-headers.yml | 1 + .github/workflows/progress.yml | 2 +- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/clean-headers.yml b/.github/workflows/clean-headers.yml index dc35b64a..8a51a7ac 100644 --- a/.github/workflows/clean-headers.yml +++ b/.github/workflows/clean-headers.yml @@ -24,10 +24,13 @@ jobs: run: | if [[ $GITHUB_EVENT_NAME == 'pull_request_target' ]] then + echo "REF: $GITHUB_REF_NAME, attempted match: `expr match "$GITHUB_REF_NAME" '.*\(^[0-9]*\)/'`" echo "HEADER_BRANCH=pr-`expr match "$GITHUB_REF_NAME" '.*\(^[0-9]*\)/'`" >> "$GITHUB_ENV" else - echo "HEADER_BRANCH=$GITHUB_REF_NAME" >> "$GITHUB_ENV" + echo "HEADER_BRANCH=$DELETED_BRANCH" >> "$GITHUB_ENV" fi + env: + DELETED_BRANCH: ${{ github.event.ref }} - name: Delete branch from OdysseyHeaders run: | cd OdysseyHeaders diff --git a/.github/workflows/copy-headers.yml b/.github/workflows/copy-headers.yml index 8248e04d..d332d631 100644 --- a/.github/workflows/copy-headers.yml +++ b/.github/workflows/copy-headers.yml @@ -34,6 +34,7 @@ jobs: run: | if [[ $GITHUB_EVENT_NAME == 'pull_request_target' ]] then + echo "REF: $GITHUB_REF_NAME, attempted match: `expr match "$GITHUB_REF_NAME" '.*\(^[0-9]*\)/'`" echo "HEADER_BRANCH=pr-`expr match "$GITHUB_REF_NAME" '.*\(^[0-9]*\)/'`" >> "$GITHUB_ENV" else echo "HEADER_BRANCH=$GITHUB_REF_NAME" >> "$GITHUB_ENV" diff --git a/.github/workflows/progress.yml b/.github/workflows/progress.yml index 262ab353..f2fc729e 100644 --- a/.github/workflows/progress.yml +++ b/.github/workflows/progress.yml @@ -13,7 +13,7 @@ jobs: with: submodules: recursive - name: Set up dependencies - run: sudo apt install -y ninja-build cmake ccache clang curl libncurses5 + run: sudo apt update && sudo apt install -y ninja-build cmake ccache clang curl libncurses5 - name: Set up python uses: actions/setup-python@v4 with: