ci: update action (#4046)

* ci: update action
This commit is contained in:
Vben
2024-08-06 22:37:47 +08:00
committed by GitHub
parent 84c8fb0ecc
commit 4bd4f7490b
14 changed files with 99 additions and 104 deletions

View File

@@ -21,7 +21,6 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
node-version: [20]
os:
- ubuntu-latest
- macos-latest
@@ -38,27 +37,8 @@ jobs:
with:
run_install: false
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: "pnpm"
- name: Find pnpm store path
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV
- name: Setup pnpm cache
uses: actions/cache@v4
with:
path: ${{ env.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Setup Node
uses: ./.github/actions/setup-node
# - name: Check Git version
# run: git --version
@@ -80,7 +60,6 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
node-version: [20]
os:
- ubuntu-latest
- macos-latest
@@ -92,17 +71,8 @@ jobs:
with:
fetch-depth: 0
- name: Install pnpm
uses: pnpm/action-setup@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: "pnpm"
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Setup Node
uses: ./.github/actions/setup-node
- name: Lint
run: pnpm run lint
@@ -113,7 +83,6 @@ jobs:
timeout-minutes: 20
strategy:
matrix:
node-version: [20]
os:
- ubuntu-latest
- macos-latest
@@ -124,17 +93,8 @@ jobs:
with:
fetch-depth: 0
- name: Install pnpm
uses: pnpm/action-setup@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: "pnpm"
- name: Install dependencies
run: pnpm install --frozen-lockfile
- name: Setup Node
uses: ./.github/actions/setup-node
- name: Typecheck
run: pnpm check:type