Skip to content

Commit 093a1fb

Browse files
committed
ci: generate release notes dynamically
1 parent 7fdd2b1 commit 093a1fb

1 file changed

Lines changed: 4 additions & 15 deletions

File tree

.github/workflows/release.yml

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,12 @@
11
name: Release WP-SSO
22

33
on:
4-
push:
5-
branches: [main]
6-
paths:
7-
- '.github/workflows/release.yml'
8-
- 'RELEASE_NOTES.md'
94
workflow_dispatch:
105
inputs:
116
version:
12-
description: 'Release version without the v prefix (for example 1.1.0)'
7+
description: 'Release version without the v prefix (for example 1.2.0)'
138
required: true
14-
default: '1.0.0'
9+
default: '1.1.0'
1510

1611
permissions:
1712
contents: write
@@ -31,11 +26,7 @@ jobs:
3126
id: version
3227
shell: bash
3328
run: |
34-
if [ "${{ github.event_name }}" = "workflow_dispatch" ]; then
35-
VERSION="${{ inputs.version }}"
36-
else
37-
VERSION="1.0.0"
38-
fi
29+
VERSION="${{ inputs.version }}"
3930
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
4031
echo "tag=v$VERSION" >> "$GITHUB_OUTPUT"
4132
@@ -58,8 +49,6 @@ jobs:
5849
cp 'WordPress SSO.xml' build/WordPress-SSO-IPS.xml
5950
6051
- name: Create tag when missing
61-
env:
62-
GH_TOKEN: ${{ github.token }}
6352
shell: bash
6453
run: |
6554
TAG="${{ steps.version.outputs.tag }}"
@@ -86,6 +75,6 @@ jobs:
8675
build/wp-sso.zip \
8776
build/WordPress-SSO-IPS.xml \
8877
--title "$TITLE" \
89-
--notes-file RELEASE_NOTES.md \
78+
--generate-notes \
9079
--verify-tag
9180
fi

0 commit comments

Comments
 (0)