File tree Expand file tree Collapse file tree 2 files changed +9
-44
lines changed Expand file tree Collapse file tree 2 files changed +9
-44
lines changed Original file line number Diff line number Diff line change 1
- # This workflow will run tests using node and then publish a package to GitHub Packages when a release is created
2
- # For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages
1
+ name : publish npm
3
2
4
- name : Release
5
3
on :
6
- push :
7
- branches :
8
- - main
9
- - next
10
- jobs :
11
4
release :
5
+ types : [published]
6
+
7
+ jobs :
8
+ publish-npm :
12
9
runs-on : ubuntu-latest
13
10
steps :
14
- - name : Get npm cache directory
15
- id : npm-cache
16
- run : |
17
- echo "::set-output name=dir::$(npm config get cache)"
18
- - uses : actions/cache@v3
19
- with :
20
- path : ${{ steps.npm-cache.outputs.dir }}
21
- key : ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
22
- restore-keys : |
23
- ${{ runner.os }}-node-
24
11
- uses : actions/checkout@v3
25
- - name : Setup Node.js
26
- uses : actions/setup-node@v3
27
- with :
28
- node-version : 16
29
- registry-url : https://registry.npmjs.org/
30
-
31
- - name : Install dependencies
32
- run : npm install
33
-
34
- - name : Test
35
- run : npm test
36
-
37
- - name : publish npm
38
- run : npm publish
39
- env :
40
- NODE_AUTH_TOKEN : ${{secrets.npm_token}}
41
-
42
- - name : Publish GHP
43
12
- uses : actions/setup-node@v3
44
13
with :
45
14
node-version : 16
46
- registry-url : https://npm.pkg.github.com/
47
- - run : npm install
15
+ registry-url : https://registry.npmjs.org/
48
16
- run : npm publish
49
17
env :
50
- NODE_AUTH_TOKEN : ${{secrets.GITHUB_TOKEN }}
18
+ NODE_AUTH_TOKEN : ${{secrets.npm_token }}
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " create-html5-boilerplate" ,
3
- "version" : " 0.2 .0" ,
3
+ "version" : " 1.0 .0" ,
4
4
"description" : " An npm based quickstart app for HTML5-Boilerplate" ,
5
5
"keywords" : [],
6
6
"homepage" : " https://html5boilerplate.com/" ,
22
22
"test" : " node --experimental-vm-modules ./node_modules/jest/bin/jest.js" ,
23
23
"lint" : " eslint lib/cli.js" ,
24
24
"format" : " prettier --write \" ./cli.js\" \" tests/*.js\" " ,
25
- "coverage" : " node --experimental-vm-modules ./node_modules/jest/bin/jest.js --coverage --collectCoverageOnlyFrom ./lib/cli.js" ,
26
- "semantic-release" : " semantic-release"
25
+ "coverage" : " node --experimental-vm-modules ./node_modules/jest/bin/jest.js --coverage --collectCoverageOnlyFrom ./lib/cli.js"
27
26
},
28
27
"files" : [
29
28
" lib/**/*" ,
46
45
"yargs-parser" : " ^21.0.1"
47
46
},
48
47
"devDependencies" : {
49
- "@semantic-release/changelog" : " ^6.0.1" ,
50
- "@semantic-release/git" : " ^10.0.1" ,
51
48
"eslint" : " ^8.18.0" ,
52
49
"eslint-config-airbnb" : " ^19.0.4" ,
53
50
"eslint-config-prettier" : " ^8.5.0" ,
You can’t perform that action at this time.
0 commit comments