From e0ae227d0af39ee1c55d167d5091889f821ce124 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 31 Oct 2023 10:50:39 -0400 Subject: SL-20546: Add viewer channel and full version to GitHub release page. (cherry picked from commit f71662225eadf1589f5331e763e02e0bb1b72137) --- .github/workflows/build.yaml | 5 +++++ 1 file changed, 5 insertions(+) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 1dd2c1d5df..9d04fbe87a 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -360,6 +360,11 @@ jobs: # name the release page for the build number so we can find it # easily (analogous to looking up a codeticket build page) name: "v${{ github.run_id }}" + # SL-20546: want the channel and version to be visible on the + # release page + body: | + ${{ needs.build.outputs.viewer_channel }} + ${{ needs.build.outputs.viewer_version }} prerelease: true generate_release_notes: true # the only reason we generate a GH release is to post build products -- cgit v1.2.3 From cac7023996d691f00101429830a23b2cef3a2f83 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 14 Nov 2023 04:09:56 -0500 Subject: SL-20546: Append generated release notes body to our explicit body. For a tag build that generates a release page, try to deduce the git branch to which the tag we're building corresponds and add that to release notes. (cherry picked from commit 9e99bb04a32f2ecc0f0b99686ce5a7adb356596d) --- .github/workflows/build.yaml | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 9d04fbe87a..c0bec11275 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -24,6 +24,7 @@ jobs: outputs: viewer_channel: ${{ steps.build.outputs.viewer_channel }} viewer_version: ${{ steps.build.outputs.viewer_version }} + viewer_branch: ${{ steps.build.outputs.viewer_branch }} imagename: ${{ steps.build.outputs.imagename }} env: AUTOBUILD_ADDRSIZE: 64 @@ -176,9 +177,17 @@ jobs: if [[ "$GITHUB_REF_TYPE" == "tag" && "${GITHUB_REF_NAME:0:12}" == "Second_Life_" ]] then viewer_channel="${GITHUB_REF_NAME%#*}" export viewer_channel="${viewer_channel//_/ }" + # Since GITHUB_REF_NAME is a tag rather than a branch, we need + # to discover to what branch this tag corresponds. Get the tip + # commit (for the tag) and then ask for branches containing it. + # Assume GitHub cloned only this tag and its containing branch. + viewer_branch="$(git branch --contains "$(git log -n 1 --format=%h)" | + grep -v '(HEAD')" else export viewer_channel="Second Life Test" + viewer_branch="${GITHUB_REF_NAME}" fi echo "viewer_channel=$viewer_channel" >> "$GITHUB_OUTPUT" + echo "viewer_branch=$viewer_branch" >> "$GITHUB_OUTPUT" # On windows we need to point the build to the correct python # as neither CMake's FindPython nor our custom Python.cmake module @@ -365,8 +374,10 @@ jobs: body: | ${{ needs.build.outputs.viewer_channel }} ${{ needs.build.outputs.viewer_version }} + ${{ needs.build.outputs.viewer_branch }} prerelease: true generate_release_notes: true + append_body: true # the only reason we generate a GH release is to post build products fail_on_unmatched_files: true files: | -- cgit v1.2.3 From a13e70aeffb87e2934f1b01f85dc2c78ea10e20c Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 14 Nov 2023 14:20:51 -0500 Subject: SL-20546: Try harder to infer the branch corresponding to build tag. (cherry picked from commit 59eeaed1187e7592fd83380045916f2d8b9d58e7) --- .github/workflows/build.yaml | 8 ++-- .github/workflows/which_branch.py | 77 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 80 insertions(+), 5 deletions(-) create mode 100644 .github/workflows/which_branch.py (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index c0bec11275..6c40c173db 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -178,11 +178,9 @@ jobs: then viewer_channel="${GITHUB_REF_NAME%#*}" export viewer_channel="${viewer_channel//_/ }" # Since GITHUB_REF_NAME is a tag rather than a branch, we need - # to discover to what branch this tag corresponds. Get the tip - # commit (for the tag) and then ask for branches containing it. - # Assume GitHub cloned only this tag and its containing branch. - viewer_branch="$(git branch --contains "$(git log -n 1 --format=%h)" | - grep -v '(HEAD')" + # to discover to what branch this tag corresponds. + viewer_branch="$(python3 .github/workflows/which_branch.py \ + --token "${{ github.token }}" ${{ github.workflow_sha }})" else export viewer_channel="Second Life Test" viewer_branch="${GITHUB_REF_NAME}" fi diff --git a/.github/workflows/which_branch.py b/.github/workflows/which_branch.py new file mode 100644 index 0000000000..802ea44b5a --- /dev/null +++ b/.github/workflows/which_branch.py @@ -0,0 +1,77 @@ +#!/usr/bin/env python3 +"""\ +@file which_branch.py +@author Nat Goodspeed +@date 2023-11-14 +@brief Discover which git branch(es) correspond to a given commit hash. + +$LicenseInfo:firstyear=2023&license=viewerlgpl$ +Copyright (c) 2023, Linden Research, Inc. +$/LicenseInfo$ +""" + +import github +import re +import sys +import subprocess + +class Error(Exception): + pass + +def branches_for(token, commit, repo=None): + """ + Use the GitHub REST API to discover which branch(es) correspond to the + passed commit hash. The commit string can actually be any of the ways git + permits to identify a commit: + + https://git-scm.com/docs/gitrevisions#_specifying_revisions + + branches_for() generates a (possibly empty) sequence of all the branches + of the specified repo for which the specified commit is the tip. + + If repo is omitted or None, assume the current directory is a local clone + whose 'origin' remote is the GitHub repository of interest. + """ + if not repo: + url = subprocess.check_output(['git', 'remote', 'get-url', 'origin'], + text=True) + parts = re.split(r'[:/]', url.rstrip()) + repo = '/'.join(parts[-2:]).removesuffix('.git') + + gh = github.MainClass.Github(token) + grepo = gh.get_repo(repo) + for branch in grepo.get_branches(): + try: + delta = grepo.compare(base=commit, head=branch.name) + except github.GithubException: + continue + + if delta.ahead_by == 0 and delta.behind_by == 0: + yield branch + +def main(*raw_args): + from argparse import ArgumentParser + parser = ArgumentParser(description= +"%(prog)s reports the branch(es) for which the specified commit hash is the tip.", + epilog="""\ +When GitHub Actions launches a tag build, it checks out the specific changeset +identified by the tag, and so 'git branch' reports detached HEAD. But we use +tag builds to build a GitHub 'release' of the tip of a particular branch, and +it's useful to be able to identify which branch that is. +""") + parser.add_argument('-t', '--token', required=True, + help="""GitHub REST API access token""") + parser.add_argument('-r', '--repo', + help="""GitHub repository name, in the form OWNER/REPOSITORY""") + parser.add_argument('commit', + help="""commit hash at the tip of the sought branch""") + + args = parser.parse_args(raw_args) + for branch in branches_for(token=args.token, commit=args.commit, repo=args.repo): + print(branch.name) + +if __name__ == "__main__": + try: + sys.exit(main(*sys.argv[1:])) + except Error as err: + sys.exit(str(err)) -- cgit v1.2.3 From e4865db0cae7dc3b4e37543cb7cd57d357048340 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Tue, 14 Nov 2023 14:30:44 -0500 Subject: SL-20546: Add PyGithub to installed Python packages. (cherry picked from commit 6654ad14eed674e894d2903e0f2ea37c4e806c0f) --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 6c40c173db..6704737409 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -81,7 +81,7 @@ jobs: path: .master-message-template - name: Install autobuild and python dependencies - run: pip3 install autobuild llsd + run: pip3 install autobuild PyGithub llsd - name: Cache autobuild packages uses: actions/cache@v3 -- cgit v1.2.3 From cfbef4e4f961cafaa004089e2055ff13de35b8dc Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Wed, 15 Nov 2023 09:44:38 -0500 Subject: SL-20546: Make dependency on build job explicit, not indirect. The release job has been dependent on sign-and-package-windows and sign-and-package-mac, each of which depends on build. But that indirect dependency doesn't convey access to ${{ needs.build.outputs.xxx }}. Add the build job to direct dependencies so release can access its outputs. (cherry picked from commit 819604d2cee6d4527cc436bebfacddf8642635ff) --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 6704737409..861f1567c6 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -331,7 +331,7 @@ jobs: version: ${{ needs.build.outputs.viewer_version }} release: - needs: [sign-and-package-windows, sign-and-package-mac] + needs: [build, sign-and-package-windows, sign-and-package-mac] runs-on: ubuntu-latest if: github.ref_type == 'tag' && startsWith(github.ref_name, 'Second_Life_') steps: -- cgit v1.2.3 From 8590ce0533a4bc273b6c0094250fe31fc8e78f1f Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 18 Dec 2023 10:59:03 -0500 Subject: DRTVWR-601: Make autobuild set vcs_url, vcs_branch, vcs_revision in viewer's autobuild-package.xml. Ensure that AUTOBUILD_VCS_BRANCH is set before the build. (cherry picked from commit b782ab73e640e434e4ed67fa8dfc951f09757585) (cherry picked from commit 6e8d4f48466a5bbad2fcc27bc2877a30e575d4ce) --- .github/workflows/build.yaml | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 861f1567c6..f127ac3f0f 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -34,6 +34,9 @@ jobs: AUTOBUILD_GITHUB_TOKEN: ${{ secrets.SHARED_AUTOBUILD_GITHUB_TOKEN }} AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables + # Direct autobuild to store vcs_url, vcs_branch and vcs_revision in + # autobuild-package.xml. + AUTOBUILD_VCS_INFO: "true" AUTOBUILD_VSVER: "170" DEVELOPER_DIR: ${{ matrix.developer_dir }} # Ensure that Linden viewer builds engage Bugsplat. @@ -199,6 +202,11 @@ 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 -- cgit v1.2.3 From 9b3d4325d9f049bc7315e3772eee2fb5e4bfc83a Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 18 Dec 2023 17:35:23 -0500 Subject: DRTVWR-601: Use viewer-build-util/which-branch to determine branch. (cherry picked from commit 2c5066f1fcc0c9f145698ef3aaec72d27bce7181) (cherry picked from commit ff1741cecae0fac6d94507fa4a6e4662219af707) --- .github/workflows/build.yaml | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f127ac3f0f..f172883ae6 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -100,10 +100,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 @@ -154,7 +161,7 @@ jobs: } repo_branch() { - git -C "$1" branch | grep '^* ' | cut -c 3- + echo "$AUTOBUILD_VCS_BRANCH" } record_dependencies_graph() { @@ -202,11 +209,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 -- cgit v1.2.3 From 8f68199ccd4beeee827ff360e2f36871cedacdfe Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 18 Jan 2024 13:34:40 -0500 Subject: SL-20546: Use branch for autobuild package as well as release page. which_branch.py has moved to viewer-build-util as a reusable action. (cherry picked from commit 09f66828ba573515c3766cce32f4746b8189efcf) --- .github/workflows/build.yaml | 8 +--- .github/workflows/which_branch.py | 77 --------------------------------------- 2 files changed, 1 insertion(+), 84 deletions(-) delete mode 100644 .github/workflows/which_branch.py (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f172883ae6..b323290f6b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -24,7 +24,7 @@ jobs: outputs: viewer_channel: ${{ steps.build.outputs.viewer_channel }} viewer_version: ${{ steps.build.outputs.viewer_version }} - viewer_branch: ${{ steps.build.outputs.viewer_branch }} + viewer_branch: ${{ steps.which-branch.outputs.branch }} imagename: ${{ steps.build.outputs.imagename }} env: AUTOBUILD_ADDRSIZE: 64 @@ -187,15 +187,9 @@ jobs: if [[ "$GITHUB_REF_TYPE" == "tag" && "${GITHUB_REF_NAME:0:12}" == "Second_Life_" ]] then viewer_channel="${GITHUB_REF_NAME%#*}" export viewer_channel="${viewer_channel//_/ }" - # Since GITHUB_REF_NAME is a tag rather than a branch, we need - # to discover to what branch this tag corresponds. - viewer_branch="$(python3 .github/workflows/which_branch.py \ - --token "${{ github.token }}" ${{ github.workflow_sha }})" else export viewer_channel="Second Life Test" - viewer_branch="${GITHUB_REF_NAME}" fi echo "viewer_channel=$viewer_channel" >> "$GITHUB_OUTPUT" - echo "viewer_branch=$viewer_branch" >> "$GITHUB_OUTPUT" # On windows we need to point the build to the correct python # as neither CMake's FindPython nor our custom Python.cmake module diff --git a/.github/workflows/which_branch.py b/.github/workflows/which_branch.py deleted file mode 100644 index 802ea44b5a..0000000000 --- a/.github/workflows/which_branch.py +++ /dev/null @@ -1,77 +0,0 @@ -#!/usr/bin/env python3 -"""\ -@file which_branch.py -@author Nat Goodspeed -@date 2023-11-14 -@brief Discover which git branch(es) correspond to a given commit hash. - -$LicenseInfo:firstyear=2023&license=viewerlgpl$ -Copyright (c) 2023, Linden Research, Inc. -$/LicenseInfo$ -""" - -import github -import re -import sys -import subprocess - -class Error(Exception): - pass - -def branches_for(token, commit, repo=None): - """ - Use the GitHub REST API to discover which branch(es) correspond to the - passed commit hash. The commit string can actually be any of the ways git - permits to identify a commit: - - https://git-scm.com/docs/gitrevisions#_specifying_revisions - - branches_for() generates a (possibly empty) sequence of all the branches - of the specified repo for which the specified commit is the tip. - - If repo is omitted or None, assume the current directory is a local clone - whose 'origin' remote is the GitHub repository of interest. - """ - if not repo: - url = subprocess.check_output(['git', 'remote', 'get-url', 'origin'], - text=True) - parts = re.split(r'[:/]', url.rstrip()) - repo = '/'.join(parts[-2:]).removesuffix('.git') - - gh = github.MainClass.Github(token) - grepo = gh.get_repo(repo) - for branch in grepo.get_branches(): - try: - delta = grepo.compare(base=commit, head=branch.name) - except github.GithubException: - continue - - if delta.ahead_by == 0 and delta.behind_by == 0: - yield branch - -def main(*raw_args): - from argparse import ArgumentParser - parser = ArgumentParser(description= -"%(prog)s reports the branch(es) for which the specified commit hash is the tip.", - epilog="""\ -When GitHub Actions launches a tag build, it checks out the specific changeset -identified by the tag, and so 'git branch' reports detached HEAD. But we use -tag builds to build a GitHub 'release' of the tip of a particular branch, and -it's useful to be able to identify which branch that is. -""") - parser.add_argument('-t', '--token', required=True, - help="""GitHub REST API access token""") - parser.add_argument('-r', '--repo', - help="""GitHub repository name, in the form OWNER/REPOSITORY""") - parser.add_argument('commit', - help="""commit hash at the tip of the sought branch""") - - args = parser.parse_args(raw_args) - for branch in branches_for(token=args.token, commit=args.commit, repo=args.repo): - print(branch.name) - -if __name__ == "__main__": - try: - sys.exit(main(*sys.argv[1:])) - except Error as err: - sys.exit(str(err)) -- cgit v1.2.3 From a8cd70123b075440c6343862349495421d12be45 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 18 Jan 2024 13:43:34 -0500 Subject: SL-20546: PyGithub was only needed for local which_branch.py. Now that which_branch.py has moved to viewer-build-util, so has the PyGithub dependency. (cherry picked from commit dd0ec112fe5ded8ed5f69b72b3df26343ca12d35) --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index b323290f6b..0cd5595e4b 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -84,7 +84,7 @@ jobs: path: .master-message-template - name: Install autobuild and python dependencies - run: pip3 install autobuild PyGithub llsd + run: pip3 install autobuild llsd - name: Cache autobuild packages uses: actions/cache@v3 -- cgit v1.2.3 From 9f326f5b960b0d039280e4c04e7eb44fc094e40e Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 15 Feb 2024 11:21:31 -0500 Subject: Engage new viewer-build-util/which-branch with relnotes output. Put whatever release notes we retrieve into the generated release page. (cherry picked from commit ff543b744ee0b0fd4dd90b46419ae50a570572ab) --- .github/workflows/build.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 0cd5595e4b..4d3dd31801 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -25,6 +25,7 @@ jobs: viewer_channel: ${{ steps.build.outputs.viewer_channel }} viewer_version: ${{ steps.build.outputs.viewer_version }} viewer_branch: ${{ steps.which-branch.outputs.branch }} + relnotes: ${{ steps.which-branch.outputs.relnotes }} imagename: ${{ steps.build.outputs.imagename }} env: AUTOBUILD_ADDRSIZE: 64 @@ -102,7 +103,7 @@ jobs: - name: Determine source branch id: which-branch - uses: secondlife/viewer-build-util/which-branch@v1 + uses: secondlife/viewer-build-util/which-branch@relnotes with: token: ${{ github.token }} @@ -377,6 +378,7 @@ jobs: ${{ needs.build.outputs.viewer_channel }} ${{ needs.build.outputs.viewer_version }} ${{ needs.build.outputs.viewer_branch }} + ${{ needs.build.outputs.relnotes }} prerelease: true generate_release_notes: true append_body: true -- cgit v1.2.3 From 603d3a865a0f619488555dd2d205e0eff4280cc5 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 26 Feb 2024 11:23:47 -0500 Subject: Try to generate release notes for this specific branch. Also try to cross-reference release page and build page. (cherry picked from commit a908b4cfa98716d4a838fc1e5a6789faa15d16cf) --- .github/workflows/build.yaml | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 4d3dd31801..6713e429cc 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -367,25 +367,30 @@ jobs: mv newview/viewer_version.txt macOS-viewer_version.txt # forked from softprops/action-gh-release - - uses: secondlife-3p/action-gh-release@v1 + - name: Create GitHub release + id: release + uses: secondlife-3p/action-gh-release@v1 with: - # name the release page for the build number so we can find it - # easily (analogous to looking up a codeticket build page) - name: "v${{ github.run_id }}" + # name the release page for the branch + name: "${{ needs.build.outputs.viewer_branch }}" # SL-20546: want the channel and version to be visible on the # release page body: | + Build ${{ github.repositoryUrl }}/actions/runs/${{ github.run_id }} ${{ needs.build.outputs.viewer_channel }} ${{ needs.build.outputs.viewer_version }} - ${{ needs.build.outputs.viewer_branch }} ${{ needs.build.outputs.relnotes }} prerelease: true generate_release_notes: true + target_commitish: ${{ github.ref }} append_body: true - # the only reason we generate a GH release is to post build products fail_on_unmatched_files: true files: | *.dmg *.exe *-autobuild-package.xml *-viewer_version.txt + + - name: post release URL + run: | + echo "::notice::Release ${{ steps.release.outputs.url }}" -- cgit v1.2.3 From d7e6a7dbd057e03984583f4524953f8ae5250f17 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 26 Feb 2024 12:20:31 -0500 Subject: Try basing the GH release on github.ref_name instead of github.ref. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Using github.ref as action-gh-release's target_commitish produces: ⚠️ GitHub release failed with status: 422 [{"resource":"Release","code":"invalid","field":"target_commitish"}] (cherry picked from commit c6a6db8488a8b3e7ea6534fbf5e2fe2b17864421) --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 6713e429cc..b156133799 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -382,7 +382,7 @@ jobs: ${{ needs.build.outputs.relnotes }} prerelease: true generate_release_notes: true - target_commitish: ${{ github.ref }} + target_commitish: ${{ github.ref_name }} append_body: true fail_on_unmatched_files: true files: | -- cgit v1.2.3 From 7c52db381c61f10aa5e4e9c5414c54c0e49d5815 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 26 Feb 2024 13:26:29 -0500 Subject: Try basing release notes on github.sha rather than github.ref_name. (cherry picked from commit 4edd78f2e54b3cd2e0b0a4b9300dfc669231dd98) --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index b156133799..1816e8b48f 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -382,7 +382,7 @@ jobs: ${{ needs.build.outputs.relnotes }} prerelease: true generate_release_notes: true - target_commitish: ${{ github.ref_name }} + target_commitish: ${{ github.sha }} append_body: true fail_on_unmatched_files: true files: | -- cgit v1.2.3 From 7ad13c851198d3ea2692c0c16f2eb844ebca8bf5 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 26 Feb 2024 15:51:31 -0500 Subject: Leverage action-gh-release's new previous_tag input. This should (!) allow us to generate full release notes relative to the previous viewer release, instead of letting action-gh-release guess incorrectly. Also try again to add to the release page a back-link to the specific build. (cherry picked from commit 88ebb92f05dade00cc8fc519cc062a458ecd48f2) --- .github/workflows/build.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 1816e8b48f..f76d4286e2 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -369,20 +369,21 @@ jobs: # forked from softprops/action-gh-release - name: Create GitHub release id: release - uses: secondlife-3p/action-gh-release@v1 + uses: secondlife-3p/action-gh-release@feat/add-generateReleaseNotes with: # name the release page for the branch name: "${{ needs.build.outputs.viewer_branch }}" # SL-20546: want the channel and version to be visible on the # release page body: | - Build ${{ github.repositoryUrl }}/actions/runs/${{ github.run_id }} + Build ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }} ${{ needs.build.outputs.viewer_channel }} ${{ needs.build.outputs.viewer_version }} ${{ needs.build.outputs.relnotes }} prerelease: true generate_release_notes: true target_commitish: ${{ github.sha }} + previous_tag: 7.1.2-release append_body: true fail_on_unmatched_files: true files: | -- cgit v1.2.3 From 3ee3e011ffe2b0d0810f61b5d35afb24ee4095a0 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Mon, 26 Feb 2024 17:05:56 -0500 Subject: Base generated release notes on new floating tag 'release' instead of on the current tag 7.1.2-release. (cherry picked from commit 27b298d8bc720ff315c8e74cc5bff9ff9ead0552) --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f76d4286e2..b3dafd43c9 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -383,7 +383,7 @@ jobs: prerelease: true generate_release_notes: true target_commitish: ${{ github.sha }} - previous_tag: 7.1.2-release + previous_tag: release append_body: true fail_on_unmatched_files: true files: | -- cgit v1.2.3 From 00d7fef75ed860596ab87904209a827fd9de867e Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Wed, 28 Feb 2024 08:45:12 -0500 Subject: Reference updated action-gh-release@v1 instead of the branch that got pulled. (cherry picked from commit b42e01d7acf5d4c55612c3a7df0e1ff6ee5ed951) --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index b3dafd43c9..8b08bb3960 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -369,7 +369,7 @@ jobs: # forked from softprops/action-gh-release - name: Create GitHub release id: release - uses: secondlife-3p/action-gh-release@feat/add-generateReleaseNotes + uses: secondlife-3p/action-gh-release@v1 with: # name the release page for the branch name: "${{ needs.build.outputs.viewer_branch }}" -- cgit v1.2.3 From 9b8800f216fb0a6efa80b76ca15d0491bd9948ee Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Fri, 1 Mar 2024 16:43:15 -0500 Subject: Now that viewer-build-util@relnotes has merged to v1, use @v1. --- .github/workflows/build.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 8b08bb3960..df49f5fa42 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -103,7 +103,7 @@ jobs: - name: Determine source branch id: which-branch - uses: secondlife/viewer-build-util/which-branch@relnotes + uses: secondlife/viewer-build-util/which-branch@v1 with: token: ${{ github.token }} -- cgit v1.2.3 From 231062d5323eca322c67c7132f96a1d402c0036c Mon Sep 17 00:00:00 2001 From: Brad Linden Date: Tue, 12 Mar 2024 17:49:19 -0700 Subject: Fix github actions dependency deprecations --- .github/workflows/build.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to '.github/workflows') diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 13798fc607..078eb1f1b8 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -60,7 +60,7 @@ jobs: ref: ${{ github.event.pull_request.head.sha || github.sha }} - name: Setup python - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: ${{ matrix.python-version }} @@ -81,7 +81,7 @@ jobs: run: pip3 install autobuild llsd - name: Cache autobuild packages - uses: actions/cache@v3 + uses: actions/cache@v4 id: cache-installables with: path: .autobuild-installables -- cgit v1.2.3