Generate Release #18
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| on: | |
| workflow_call: | |
| inputs: | |
| stream_name: | |
| description: "Release Tag (e.g. stable, latest)" | |
| type: string | |
| required: true | |
| workflow_dispatch: | |
| inputs: | |
| handwritten: | |
| description: "Small Changelog about changes in this build" | |
| stream_name: | |
| description: "Release Tag (e.g. stable, latest)" | |
| required: true | |
| type: choice | |
| options: | |
| - '["stable"]' | |
| permissions: | |
| contents: write | |
| name: Generate Release | |
| jobs: | |
| generate-release: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| version: ${{ fromJson( inputs.stream_name ) }} | |
| steps: | |
| - name: Checkout last 500 commits (for <commits> to work) | |
| uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd # v5 | |
| with: | |
| fetch-depth: 500 | |
| - name: Setup Just | |
| uses: extractions/setup-just@e33e0265a09d6d736e2ee1e0eb685ef1de4669ff # v3 | |
| - name: Check Just Syntax | |
| shell: bash | |
| run: | | |
| just check | |
| - name: Generate Release Text | |
| id: generate-release-text | |
| shell: bash | |
| run: | | |
| just changelogs "${{ matrix.version }}" "${{ inputs.handwritten }}" | |
| source ./output.env | |
| echo "title=${TITLE}" >> $GITHUB_OUTPUT | |
| echo "tag=${TAG}" >> $GITHUB_OUTPUT | |
| - name: Create Release | |
| uses: softprops/action-gh-release@5be0e66d93ac7ed76da52eca8bb058f665c3a5fe # v2 | |
| if: contains(fromJson('["stable"]'), matrix.version) && contains(fromJson('["schedule", "workflow_dispatch", "workflow_call"]'), github.event_name) | |
| with: | |
| name: ${{ steps.generate-release-text.outputs.title }} | |
| tag_name: ${{ steps.generate-release-text.outputs.tag }} | |
| body_path: ./changelog.md | |
| make_latest: ${{ matrix.version == 'stable' }} | |
| prerelease: false |