forked from ublue-os/bluefin
-
Notifications
You must be signed in to change notification settings - Fork 0
62 lines (55 loc) · 1.86 KB
/
Copy pathgenerate-release.yml
File metadata and controls
62 lines (55 loc) · 1.86 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
on:
workflow_call:
inputs:
stream_name:
description: "Release Tag (e.g. stable)"
type: string
required: true
workflow_dispatch:
inputs:
handwritten:
description: "Small Changelog about changes in this build"
stream_name:
description: "Release Tag (e.g. stable)"
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@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
with:
fetch-depth: 500
- name: Setup Just
uses: extractions/setup-just@f8a3cce218d9f83db3a2ecd90e41ac3de6cdfd9b # 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@a06a81a03ee405af7f2048a818ed3f03bbf83c7b # v2
if: contains(fromJson('["stable"]'), matrix.version) && (github.event.schedule == '0 1 * * TUE' || contains(fromJson('["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