File tree 2 files changed +54
-1
lines changed
2 files changed +54
-1
lines changed Original file line number Diff line number Diff line change
1
+ name : Publish
2
+
3
+ on :
4
+ push :
5
+ tags :
6
+ - ' v*' # Push events to matching v*, i.e. v1.0, v20.15.10
7
+
8
+ jobs :
9
+ build :
10
+ # Run scripts on Linux
11
+ runs-on : ubuntu-latest
12
+ steps :
13
+ # Use github actions default to checkout corresponding branch
14
+ - uses : actions/checkout@v2
15
+
16
+ # Use github actions to install node at least 14 version
17
+ - name : Setup node
18
+ uses : actions/setup-node@v2
19
+ with :
20
+ node-version : ' 14'
21
+ registry-url : ' https://registry.npmjs.org'
22
+
23
+ # Use github actions to install pnpm at least 6 version
24
+ - name : Install pnpm
25
+ uses : pnpm/action-setup@v2
26
+ with :
27
+ version : 6
28
+
29
+ # Install dependencies
30
+ - name : Install dependencies
31
+ run : pnpm install
32
+
33
+ # Run build
34
+ - name : Build
35
+ run : pnpm build
36
+
37
+ # Use github actions to create release with tagName, commitMessage and committerName
38
+ - name : Create Release for Tag
39
+ id : release_tag
40
+ uses : yyx990803/release-tag@master
41
+ env :
42
+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
43
+ with :
44
+ tag_name : ${{ github.ref }}
45
+ body : |
46
+ ${{github.event.head_commit.message}} by **@${{github.event.head_commit.committer.name}}**
47
+
48
+ # Publish to npm
49
+ # !It must configure npm token and tokenName same with NPM_PUBLISH_TOKEN
50
+ - name : Publish to npm registry
51
+ run : |
52
+ npm publish --access public
53
+ env :
54
+ NODE_AUTH_TOKEN : ${{ secrets.NPM_PUBLISH_TOKEN }}
Original file line number Diff line number Diff line change 24
24
},
25
25
methods: {
26
26
complete () {
27
- debugger
28
27
console .log (' complete' , arguments )
29
28
},
30
29
fileComplete () {
You can’t perform that action at this time.
0 commit comments