Skip to content

Commit

Permalink
Update GitHub actions
Browse files Browse the repository at this point in the history
  • Loading branch information
grubersjoe committed Nov 7, 2023
1 parent 5195d40 commit e37f8f5
Showing 1 changed file with 31 additions and 11 deletions.
42 changes: 31 additions & 11 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,47 @@
name: CI

on: [push, pull_request]
on:
- push
- pull_request

jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
- name: Checkout
uses: actions/checkout@v3

- name: Install Node
uses: actions/setup-node@v3
with:
node-version: 18

- name: Install pnpm
uses: pnpm/action-setup@v2
id: pnpm-install
with:
node-version: '16'
version: 8
run_install: false

- name: Get pnpm store directory
id: pnpm-cache
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
- name: Cache dependencies
uses: actions/cache@v2
- uses: actions/cache@v3
name: Setup pnpm cache
with:
path: './node_modules'
key: ${{ runner.os }}-modules-${{ hashFiles('./yarn.lock') }}
path: ${{ steps.pnpm-cache.outputs.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-
- name: Install dependencies
run: yarn install --frozen-lockfile --ignore-scripts
run: pnpm install

- name: Run type checks (TypeScript)
run: yarn --ignore-scripts tsc
run: pnpm tsc

- name: Run linter (ESLint)
run: yarn --ignore-scripts lint
run: pnpm lint

0 comments on commit e37f8f5

Please sign in to comment.