diff options
author | Nat Goodspeed <nat@lindenlab.com> | 2023-12-18 17:35:23 -0500 |
---|---|---|
committer | Nat Goodspeed <nat@lindenlab.com> | 2023-12-18 17:35:23 -0500 |
commit | 2c5066f1fcc0c9f145698ef3aaec72d27bce7181 (patch) | |
tree | b6c67792e37613ab9e3a5c2644030977bea0b481 /.github | |
parent | 6f4dcd58b75b536f78eaa1314ce3daa76621c283 (diff) |
DRTVWR-601: Use viewer-build-util/which-branch to determine branch.
Diffstat (limited to '.github')
-rw-r--r-- | .github/workflows/build.yaml | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index ad494cb3a4..dee1ca24ab 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -99,10 +99,17 @@ jobs: if: runner.os == 'Windows' run: choco install nsis-unicode + - name: Determine source branch + id: which-branch + uses: secondlife/viewer-build-util/which-branch@v1 + with: + token: ${{ github.token }} + - name: Build id: build shell: bash env: + AUTOBUILD_VCS_BRANCH: ${{ steps.which-branch.outputs.branch }} RUNNER_OS: ${{ runner.os }} run: | # set up things the viewer's build.sh script expects @@ -153,7 +160,7 @@ jobs: } repo_branch() { - git -C "$1" branch | grep '^* ' | cut -c 3- + echo "$AUTOBUILD_VCS_BRANCH" } record_dependencies_graph() { @@ -195,11 +202,6 @@ jobs: fi export PYTHON_COMMAND_NATIVE="$(native_path "$PYTHON_COMMAND")" - # branch will be something like "origin/mybranch" - branch="$(git branch -r --contains ${{ github.event.pull_request.head.sha || github.sha }} | head -n 1)" - # strip off "origin/" - export AUTOBUILD_VCS_BRANCH="${branch#*/}" - ./build.sh # Each artifact is downloaded as a distinct .zip file. Multiple jobs |