File tree Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change 7
7
pull_request :
8
8
branches :
9
9
- master
10
+ release :
11
+ types : [released, prereleased]
10
12
11
13
jobs :
12
14
test :
54
56
else
55
57
echo "Skipping canary publish due to a fork/PR..."
56
58
fi
59
+
60
+ publish :
61
+ # publish to npm only when doing the release
62
+ if : ${{ github.event_name == 'release' }}
63
+ name : Publish Release
64
+ runs-on : ubuntu-latest
65
+ steps :
66
+ - name : Checkout Master
67
+ uses : actions/checkout@v1
68
+ - name : Use Node
69
+ uses : actions/setup-node@v1
70
+ with :
71
+ node-version : 14
72
+ - name : Install Dependencies using Yarn
73
+ run : yarn install
74
+ - name : Build
75
+ run : yarn build
76
+ - name : Release
77
+ run : echo "//registry.npmjs.org/:_authToken=${{secrets.NODE_AUTH_TOKEN}}" > ~/.npmrc && TAG=${GITHUB_REF#"refs/tags/"} npm run release
You can’t perform that action at this time.
0 commit comments