Skip to content

Add Github Actions

Add Github Actions #2

Workflow file for this run

name: Pull Request
on: [pull_request]
jobs:
install:
name: Install dependencies
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Cache node_modules
uses: actions/cache@v2
with:
path: node_modules
key: ${{ runner.os }}-${{ hashFiles('**/package-lock.json') }}
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
- name: Install dependencies
run: npm i
build:
name: Build files
runs-on: ubuntu-latest
steps:
- name: Run build
run: npm run build
lint:
name: Apply linter
runs-on: ubuntu-latest
needs: install
steps:
- name: Run linter
run: npm run lint
test:
name: Test
runs-on: ubuntu-latest
needs: install
steps:
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
- name: Run tests
run: npm run test