jak-project/.github/workflows/draft-new-release.yaml
Tyler Wilding e74bd3b32b
ci: Add an automated release process (#1262)
* ci: bring over some of my code to enable the process

* ci: cleanup builds a bit and add release stuff

* ci: fix paths and such after debugging

* ci: fix flowchart

* cmake: easily toggle between building everything dyn or statically linked

* ci: build release artifacts statically linked

* ci: fix some issues after testing once again, linux binaries are still too big
2022-03-29 22:47:08 -04:00

55 lines
1.6 KiB
YAML

name: Draft Release
on:
workflow_dispatch:
inputs:
bump:
description: 'Semver Bump Type'
required: true
default: 'patch'
type: choice
options:
- patch
- minor
- major
jobs:
cut-release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
# Docs - https://github.com/mathieudutour/github-tag-action
# Workflows cannot trigger other workflows implicitly
# - https://github.community/t/github-actions-workflow-not-triggering-with-tag-push/17053/7
- name: Bump Version and Push Tag
if: github.repository == 'open-goal/jak-project'
id: tag_version
uses: mathieudutour/github-tag-action@v6.0
with:
github_token: ${{ secrets.BOT_PAT }}
tag_prefix: v
default_bump: ${{ github.event.inputs.bump }}
# Generate the Release Notes
# TODO
# - name: Generate Release Notes
# env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# COMMIT_SHA: ${{ github.SHA }}
# run: |
# cd ./.github/workflows/scripts/releases/generate-release-notes
# npm ci
# node index.js
# mv ./release-notes.md ${GITHUB_WORKSPACE}/release-notes.md
# ls
# Docs - https://github.com/softprops/action-gh-release
- name: Create a GitHub Release
uses: softprops/action-gh-release@v1
if: github.repository == 'open-goal/jak-project' && steps.tag_version.outputs.new_tag
with:
draft: true
prerelease: false
tag_name: ${{ steps.tag_version.outputs.new_tag }}