Skip to content

Commit dbab4c9

Browse files
author
realtag
committed
Publish main repeater builds to release
1 parent a279478 commit dbab4c9

1 file changed

Lines changed: 16 additions & 2 deletions

File tree

.github/workflows/build-custom-repeater-binaries.yml

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,19 +64,31 @@ jobs:
6464
fi
6565
6666
- name: Set Release Metadata
67-
if: github.event_name == 'release' || startsWith(github.ref, 'refs/tags/')
67+
if: github.event_name == 'release' || startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/main'
6868
run: |
6969
set -euo pipefail
7070
7171
if [ "${{ github.event_name }}" = "release" ]; then
7272
release_tag="${{ github.event.release.tag_name }}"
73+
elif [ "${GITHUB_REF}" = "refs/heads/main" ]; then
74+
release_tag="custom-repeater-latest"
7375
else
7476
release_tag="${GITHUB_REF_NAME}"
7577
fi
7678
7779
echo "RELEASE_TAG=${release_tag}" >> "${GITHUB_ENV}"
7880
echo "RELEASE_NAME=Repeater Firmware ${release_tag}" >> "${GITHUB_ENV}"
7981
82+
- name: Update Rolling Release Tag
83+
if: github.ref == 'refs/heads/main'
84+
run: |
85+
set -euo pipefail
86+
87+
git config user.name "github-actions[bot]"
88+
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
89+
git tag -f "${RELEASE_TAG}" "${GITHUB_SHA}"
90+
git push --force origin "refs/tags/${RELEASE_TAG}"
91+
8092
- name: Upload Workflow Artifacts
8193
uses: actions/upload-artifact@v4
8294
with:
@@ -86,8 +98,10 @@ jobs:
8698

8799
- name: Upload Release Assets
88100
uses: softprops/action-gh-release@v2
89-
if: github.event_name == 'release' || startsWith(github.ref, 'refs/tags/')
101+
if: github.event_name == 'release' || startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/main'
90102
with:
91103
tag_name: ${{ env.RELEASE_TAG }}
92104
name: ${{ env.RELEASE_NAME }}
105+
prerelease: ${{ github.ref == 'refs/heads/main' }}
106+
overwrite_files: true
93107
files: out/*

0 commit comments

Comments
 (0)