File tree Expand file tree Collapse file tree 1 file changed +39
-0
lines changed Expand file tree Collapse file tree 1 file changed +39
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Publish to npm
2
+
3
+ on :
4
+ release :
5
+ types :
6
+ - created
7
+
8
+ jobs :
9
+ publish :
10
+ runs-on : ubuntu-latest
11
+
12
+ steps :
13
+ - name : Checkout repository
14
+ uses : actions/checkout@v4
15
+
16
+ - name : Set up Node.js
17
+ uses : actions/setup-node@v4
18
+ with :
19
+ node-version : " 20.x"
20
+
21
+ - name : Install yarn
22
+ run : npm install -g yarn
23
+
24
+ - name : Check cache for packages already installed
25
+ uses : actions/cache@v3
26
+ with :
27
+ path : " **/node_modules"
28
+ key : yarn-${{ runner.os }}-${{ hashFiles('**/yarn.lock') }}
29
+
30
+ - name : Install dependencies
31
+ run : yarn install
32
+
33
+ - name : Build package
34
+ run : yarn build
35
+
36
+ - name : Publish to npm
37
+ run : npm publish
38
+ env :
39
+ NODE_AUTH_TOKEN : ${{ secrets.NPM_PUBLISH_TOKEN }}
You can’t perform that action at this time.
0 commit comments