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 1212 build :
1313 name : Check codebase (lint and typecheck)
1414 runs-on : ubuntu-latest
15- strategy :
16- matrix :
17- node-version : [ 18.x ]
1815 steps :
19- - uses : actions/checkout@v2
20- - uses : actions/setup-node@v2
21- with :
22- node-version : ${{ matrix.node-version }}
23-
24- - uses : pnpm/action-setup@v2.2.2
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
4218
4319 - name : Check Code ${{ matrix.node-version }}
4420 run : pnpm lint
Original file line number Diff line number Diff line change 1818 pull-requests : write
1919
2020 steps :
21- - uses : actions/checkout@v2
22- - uses : actions/setup-node@v3
23- with :
24- node-version : 18
25-
26- - uses : pnpm/action-setup@v2.2.2
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
4423
4524 - name : Build packages
4625 run : pnpm run build
4928 id : changesets
5029 uses : changesets/action@v1
5130 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
5531 version : pnpm run version
5632 publish : pnpm changeset publish
5733 env :
You can’t perform that action at this time.
0 commit comments