Pass through input channel to select the tag channel name

master
Brad Linden 2024-06-17 17:55:29 -07:00
parent b9a8b3b240
commit dd64c39d64
2 changed files with 4 additions and 8 deletions

View File

@ -1,12 +1,6 @@
name: Build
on:
workflow_dispatch:
inputs:
release_run:
type: boolean
description: Do a release of this build
default: false
pull_request:
push:
branches: ["main", "release/*", "project/*"]

View File

@ -27,8 +27,10 @@ jobs:
tag-release:
runs-on: ubuntu-latest
steps:
- name: Setup Date Env
- name: Setup Env Vars
run: |
CHANNEL="${{ inputs.channel }}"
echo VIEWER_CHANNEL="Second_Life_${CHANNEL:-Develop}" >> ${GITHUB_ENV}
echo NIGHTLY_DATE=$(date --rfc-3339=date) >> ${GITHUB_ENV}
- name: Update Tag
uses: actions/github-script@v7.0.1
@ -39,6 +41,6 @@ jobs:
github.rest.git.createRef(
owner: context.repo.owner,
repo: context.repo.repo,
ref: "refs/tags/Second_Life_Develop#${{ env.NIGHTLY_DATE }}",
ref: "refs/tags/${{ env.VIEWER_CHANNEL }}#${{ env.NIGHTLY_DATE }}",
sha: context.sha
)