File tree Expand file tree Collapse file tree 3 files changed +25
-11
lines changed Expand file tree Collapse file tree 3 files changed +25
-11
lines changed Original file line number Diff line number Diff line change 6
6
- main
7
7
8
8
jobs :
9
- build :
10
- name : Build
11
- uses : luos-io/sdk-web/.github/workflows/build.yml@main
12
9
publish :
13
10
name : Publish
14
11
runs-on : ubuntu-latest
15
- needs : build
16
12
steps :
17
13
- name : Checkout
18
14
uses : actions/checkout@v2
19
15
20
16
- name : Setup NodeJS
21
17
uses : actions/setup-node@v2
22
18
with :
23
- node-version : ' 14 .x'
19
+ node-version : ' 16 .x'
24
20
registry-url : ' https://npm.pkg.github.com'
25
21
scope : ' @luos-io'
26
22
23
+ - name : Install dependencies
24
+ run : yarn
25
+
26
+ - name : Build package
27
+ run : yarn build
28
+
27
29
- name : Publish GitHub Packages
28
30
run : yarn publish --access public
29
31
env :
30
- NODE_AUTH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
32
+ NODE_AUTH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
31
33
32
34
- name : Setup NodeJS
33
35
uses : actions/setup-node@v2
34
36
with :
35
- node-version : ' 14 .x'
37
+ node-version : ' 16 .x'
36
38
registry-url : ' https://registry.npmjs.org'
37
39
scope : ' @luos-io'
38
40
41
+ - name : Install dependencies
42
+ run : yarn
43
+
44
+ - name : Build package
45
+ run : yarn build
46
+
39
47
- name : Publish NPM
40
48
run : yarn publish --access public
41
49
env :
42
- NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
50
+ NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
Original file line number Diff line number Diff line change 4
4
5
5
### Workflow
6
6
7
- You can use [ ACT] ( https://github.com/nektos/act#installation-through-package-managers ) to validate the workflows locally :
7
+ You can use [ ACT] ( https://github.com/nektos/act#installation-through-package-managers ) to validate the workflows locally:
8
8
9
9
1 . Install ACT (See link for other systems):
10
10
11
11
``` sh
12
12
brew install act
13
13
```
14
14
15
- 2 . Setup secrets variables in the ` .act/.secrets ` file :
15
+ 2 . Setup secrets variables in the ` .act/.secrets ` file:
16
16
17
17
``` yml
18
18
NPM_TOKEN=
19
19
GITHUB_TOKEN=
20
20
```
21
+
22
+ 3 . Run the workflow locally:
23
+
24
+ ``` sh
25
+ act --container-architecture=linux/amd64 --secret-file ./.act/.secrets -P ubuntu-latest=node:16 push -v
26
+ ```
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " @luos-io/sdk-web" ,
3
- "version" : " 1.0.3 " ,
3
+ "version" : " 1.0.4 " ,
4
4
"author" : " Luos" ,
5
5
"description" : " " ,
6
6
"license" : " MIT" ,
You can’t perform that action at this time.
0 commit comments