File tree Expand file tree Collapse file tree 2 files changed +40
-1
lines changed Expand file tree Collapse file tree 2 files changed +40
-1
lines changed Original file line number Diff line number Diff line change
1
+ name : Release
2
+
3
+ on :
4
+ push :
5
+ branches :
6
+ - master
7
+
8
+ jobs :
9
+ release :
10
+ name : Release
11
+ runs-on : ubuntu-latest
12
+ steps :
13
+ - name : Checkout Repo
14
+ uses : actions/checkout@master
15
+ with :
16
+ # This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits
17
+ fetch-depth : 0
18
+
19
+ - name : Setup Node.js 12.x
20
+ uses : actions/setup-node@master
21
+ with :
22
+ node-version : 12.x
23
+
24
+ - name : Install pnpm
25
+ run : npm i -g pnpm
26
+
27
+ - name : Install Dependencies
28
+ run : pnpm i
29
+
30
+ - name : Create Release Pull Request or Publish to npm
31
+ id : changesets
32
+ uses : changesets/action@master
33
+ with :
34
+ # This expects you to have a script called release which does a build for your packages and calls changeset publish
35
+ publish : pnpm release
36
+ env :
37
+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
38
+ NPM_TOKEN : ${{ secrets.NPM_TOKEN }}
Original file line number Diff line number Diff line change 15
15
"postinstall" : " husky install" ,
16
16
"prepublishOnly" : " pinst --disable" ,
17
17
"publish" : " pnpm -r publish --dry-run" ,
18
- "postpublish" : " pinst --enable"
18
+ "postpublish" : " pinst --enable" ,
19
+ "release" : " pnpm build && changeset release"
19
20
},
20
21
"private" : true ,
21
22
"repository" : {
You can’t perform that action at this time.
0 commit comments