Fix: prevent middleware log errors #93
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: π Verify pull requests | |
on: | |
pull_request: | |
env: | |
PNPM_VERSION: 8 | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
defaults: | |
run: | |
shell: bash | |
steps: | |
- uses: actions/setup-node@v3 | |
id: setup-node | |
with: | |
node-version: 'lts/*' | |
- uses: pnpm/action-setup@v2 | |
id: pnpm-install | |
with: | |
version: ${{ env.PNPM_VERSION }} | |
run_install: false | |
- uses: actions/checkout@v3 | |
id: setup-git-checkout | |
with: | |
fetch-depth: 25 | |
- id: pnpm-cache-path | |
run: | | |
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT | |
- uses: actions/cache@v3 | |
name: ποΈ Setup pnpm cache | |
with: | |
path: ${{ steps.pnpm-cache-path.outputs.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 --strict-peer-dependencies | |
- name: π¨ Build | |
run: pnpm build | |
- uses: actions/cache@v3 | |
name: ποΈ Cache build | |
timeout-minutes: 10 | |
id: cache-build | |
with: | |
path: ./* | |
key: ${{ github.sha }}-${{ github.run_number }} | |
test: | |
runs-on: ubuntu-latest | |
needs: build | |
defaults: | |
run: | |
shell: bash | |
strategy: | |
matrix: | |
node-version: [18.x, 20.x, 21.x] | |
steps: | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- uses: pnpm/action-setup@v2 | |
id: pnpm-install | |
with: | |
version: ${{ env.PNPM_VERSION }} | |
run_install: false | |
- uses: actions/cache@v3 | |
name: ποΈ Restore build cache | |
timeout-minutes: 5 | |
id: restore-build | |
with: | |
path: ./* | |
key: ${{ github.sha }}-${{ github.run_number }} | |
- name: π§ͺ Tests | |
run: pnpm test | |
lint: | |
runs-on: ubuntu-latest | |
needs: build | |
defaults: | |
run: | |
shell: bash | |
steps: | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: 'lts/*' | |
- uses: pnpm/action-setup@v2 | |
id: pnpm-install | |
with: | |
version: ${{ env.PNPM_VERSION }} | |
run_install: false | |
- uses: actions/cache@v3 | |
name: ποΈ Restore build cache | |
timeout-minutes: 5 | |
id: restore-build | |
with: | |
path: ./* | |
key: ${{ github.sha }}-${{ github.run_number }} | |
- name: β¨ Lint | |
run: pnpm lint |