File tree Expand file tree Collapse file tree 1 file changed +26
-0
lines changed Expand file tree Collapse file tree 1 file changed +26
-0
lines changed Original file line number Diff line number Diff line change @@ -2,6 +2,21 @@ name: Release
2
2
3
3
on :
4
4
workflow_dispatch :
5
+ inputs :
6
+ releaseVersion :
7
+ type : string
8
+ required : true
9
+ description : The version of this release. Must be a semantic version of the form X.Y.Z.
10
+ dry_run :
11
+ type : boolean
12
+ required : true
13
+ default : false
14
+ description : Dry run, will not push branches or upload the artifacts.
15
+ skip_tag :
16
+ type : boolean
17
+ required : true
18
+ default : false
19
+ description : If true, don't tag this release, just push it.
5
20
6
21
jobs :
7
22
release :
20
35
- name : Package
21
36
run : ./build-package.sh
22
37
- name : Upload
38
+ if : ${{ github.event.inputs.dry_run != 'true' }}
23
39
run : npm publish
24
40
env :
25
41
NODE_AUTH_TOKEN : ${{ secrets.NPM_AUTH_TOKEN }}
42
+ - name : Tag release
43
+ if : ${{ github.event.inputs.skip_tag != 'true' }}
44
+ run : |
45
+ git config --global user.name 'Github Bot'
46
+ git config --global user.email '<>'
47
+ git tag -a ${{ github.events.inputs.version }}
48
+ - name : Push tag
49
+ if : ${{ github.event.inputs.dry_run != 'true' }}
50
+ run : |
51
+ git push ${{ github.events.inputs.version }}
You can’t perform that action at this time.
0 commit comments