Skip to content

chore: update labelling workflow #1086

chore: update labelling workflow

chore: update labelling workflow #1086

Workflow file for this run

on:
push:
branches:
- main
pull_request:
branches:
- "*"
workflow_dispatch:
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [macos-latest, ubuntu-latest, windows-latest]
steps:
- name: Clone repository
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: "18.x"
- name: npm latest
run: npm i -g npm@8 && npm i -g npm@latest
- name: Cache Node Modules
id: cache-node-modules
uses: actions/cache@v3
env:
cache-name: cache-node-modules
with:
path: |
node_modules
client/node_modules
server/node_modules
coc/node_modules
test/e2e/node_modules
test/protocol/node_modules
test/protocol/projects/hardhat/node_modules
key: ${{ runner.os }}-node-modules-${{ hashFiles('**/package-lock.json') }}
- name: Install dependencies
if: steps.cache-node-modules.outputs.cache-hit != 'true'
run: npm install
- name: Lint
run: npm run lint
- name: Download foundryup
if: runner.os != 'Windows'
run: curl -L https://foundry.paradigm.xyz | bash
- name: Install foundry
if: runner.os != 'Windows'
run: ${XDG_CONFIG_HOME:-$HOME}/.foundry/bin/foundryup
- name: Build project
run: npm run build
- name: Run server tests
run: npm run test:codecov
- name: Run protocol tests
run: npm run test:protocol
- name: Cache VS Code client
id: cache-vscode
uses: actions/cache@v3
env:
cache-name: cache-vscode
with:
path: .vscode-test
key: ${{ runner.os }}-vscode-1.86.0
- name: Run E2E tests
uses: coactions/setup-xvfb@v1.0.1
with:
run: npm run test:e2e
- name: Package the extension
run: npm run package