File tree Expand file tree Collapse file tree 3 files changed +27
-52
lines changed Expand file tree Collapse file tree 3 files changed +27
-52
lines changed Original file line number Diff line number Diff line change
1
+ name : Setup
2
+ description : Setup Build Step
3
+ inputs :
4
+ node-version :
5
+ required : true
6
+ default : ' 18.x'
7
+
8
+ runs :
9
+ using : " composite"
10
+ steps :
11
+ - uses : pnpm/action-setup@v3
12
+ with :
13
+ version : 7
14
+
15
+ - name : Use Node.js
16
+ uses : actions/setup-node@v4
17
+ with :
18
+ node-version : ${{ inputs.node-version }}
19
+ cache : ' pnpm'
20
+
21
+ - name : Install dependencies
22
+ shell : bash
23
+ run : pnpm install
Original file line number Diff line number Diff line change 12
12
build :
13
13
name : Check codebase (lint and typecheck)
14
14
runs-on : ubuntu-latest
15
- strategy :
16
- matrix :
17
- node-version : [ 18.x ]
18
15
steps :
19
- - uses : actions/checkout@v2
20
- - uses : actions/setup-node@v2
21
- with :
22
- node-version : ${{ matrix.node-version }}
23
-
24
-
25
- with :
26
- version : 7
27
-
28
- - name : Get pnpm store directory
29
- id : pnpm-cache
30
- run : echo "::set-output name=pnpm_cache_dir::$(pnpm store path)"
31
-
32
- - name : Setup pnpm cache
33
- uses : actions/cache@v3
34
- with :
35
- path : ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }}
36
- key : ${{ runner.os }}-pnpm-store-${{ hashFiles('./pnpm-lock.yaml') }}
37
- restore-keys : |
38
- ${{ runner.os }}-pnpm-store-
39
-
40
- - name : Install dependencies
41
- run : pnpm install
16
+ - uses : actions/checkout@v4
17
+ - uses : ./.github/actions/setup
42
18
43
19
- name : Check Code ${{ matrix.node-version }}
44
20
run : pnpm lint
Original file line number Diff line number Diff line change 18
18
pull-requests : write
19
19
20
20
steps :
21
- - uses : actions/checkout@v2
22
- - uses : actions/setup-node@v3
23
- with :
24
- node-version : 18
25
-
26
-
27
- with :
28
- version : 7
29
-
30
- - name : Get pnpm store directory
31
- id : pnpm-cache
32
- run : echo "::set-output name=pnpm_cache_dir::$(pnpm store path)"
33
-
34
- - name : Setup pnpm cache
35
- uses : actions/cache@v3
36
- with :
37
- path : ${{ steps.pnpm-cache.outputs.pnpm_cache_dir }}
38
- key : ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
39
- restore-keys : |
40
- ${{ runner.os }}-pnpm-store-
41
-
42
- - name : Install dependencies
43
- run : pnpm install
21
+ - uses : actions/checkout@v4
22
+ - uses : ./.github/actions/setup
44
23
45
24
- name : Build packages
46
25
run : pnpm run build
49
28
id : changesets
50
29
uses : changesets/action@v1
51
30
with :
52
- # Note: Our `package.json:scripts.version` currently doesn't have `--fix-lockfile` for
53
- # `pnpm install` because of a PNPM bug of some kind.
54
- # https://github.com/FormidableLabs/spectacle/issues/1156
55
31
version : pnpm run version
56
32
publish : pnpm changeset publish
57
33
env :
You can’t perform that action at this time.
0 commit comments