name: Steam Frame release # Publishes a GitHub pre-release with the notes in docs/releases/.md, either for a pushed # frame- tag or, run by hand (Actions > Steam Frame release > Run workflow), for a tag # GitHub creates on the commit the run is for. Source only: the game is built from the player's own # disc and nothing built from it is distributed (README, Requirements). The v* tags stay with # package.yml, which packages upstream's Windows installer. on: push: tags: ['frame-*'] workflow_dispatch: inputs: tag: description: Release tag, frame-; docs/releases/.md holds its notes required: true default: frame-beta-1 permissions: contents: write jobs: release: runs-on: ubuntu-latest steps: - uses: actions/checkout@v7 with: persist-credentials: false - name: Publish the pre-release env: GH_TOKEN: ${{ github.token }} TAG: ${{ github.event_name == 'workflow_dispatch' && inputs.tag || github.ref_name }} REPOSITORY: ${{ github.repository }} DISPATCHED: ${{ github.event_name == 'workflow_dispatch' }} run: | case "$TAG" in frame-*) ;; *) echo "::error::Steam Frame release tags start with frame-, not '$TAG'"; exit 1 ;; esac notes="docs/releases/${TAG}.md" if [ ! -f "$notes" ]; then echo "::error::No release notes at $notes" exit 1 fi if [ "$DISPATCHED" = "true" ]; then # GitHub creates the tag on this run's commit. where=(--target "$GITHUB_SHA") else where=(--verify-tag) fi gh release create "$TAG" --repo "$REPOSITORY" "${where[@]}" --prerelease \ --title "WiiCompiled VR for the Steam Frame ${TAG#frame-}" --notes-file "$notes"