File tree 1 file changed +10
-3
lines changed
1 file changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -20,20 +20,27 @@ jobs:
20
20
21
21
# https://github.com/actions-ecosystem/action-regex-match
22
22
- uses : actions-ecosystem/action-regex-match@v2
23
- id : version
23
+ id : version-regex
24
24
with :
25
25
# Parse version from head branch
26
26
text : ${{ github.head_ref }}
27
27
# match: preprare-release/xx.xx.xx
28
28
regex : ' ^prepare-release\/(\d+\.\d+\.\d+)(?:-(alpha|beta)\.\d+)?$'
29
29
30
+ - name : Extract version
31
+ id : get_version
32
+ run : |
33
+ version=${{ steps.version-regex.outputs.match }}
34
+ version=${version/'prepare-release/'/''}
35
+ echo "version=$version" >> $GITHUB_OUTPUT
36
+
30
37
- name : Prepare release
31
38
uses : getsentry/action-prepare-release@v1
32
- if : github.event.pull_request.merged == true && steps.version.outputs.match != ''
39
+ if : github.event.pull_request.merged == true && steps.version-regex .outputs.match != '' && steps.get_version.outputs.version != ''
33
40
env :
34
41
GITHUB_TOKEN : ${{ secrets.GH_RELEASE_PAT }}
35
42
with :
36
- version : ${{ steps.version .outputs.group1 }}
43
+ version : ${{ steps.get_version .outputs.version }}
37
44
force : false
38
45
merge_target : master
39
46
craft_config_from_merge_target : true
You can’t perform that action at this time.
0 commit comments