Skip to content

feat(jstzd): insert jstz bootstrap contracts #2773

feat(jstzd): insert jstz bootstrap contracts

feat(jstzd): insert jstz bootstrap contracts #2773

Workflow file for this run

name: Continuous Integration
on:
pull_request:
push:
branches: [main]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref_name != 'main' }}
jobs:
commitlint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: wagoid/commitlint-github-action@v6
# FIXME(https://linear.app/tezos/issue/JSTZ-49):
# Add build and tests for LIGO contracts
build:
name: Build
runs-on: [x86_64, linux, nix]
needs: [commitlint]
steps:
- uses: actions/checkout@v4
- run: nix --version
- name: Format
run: nix --accept-flake-config fmt -- --fail-on-change
- name: Prevent blst
run: nix --accept-flake-config develop -j auto --command sh -c '[ -z "$(cargo tree | grep blst)" ]'
- name: Build
run: nix --accept-flake-config --log-format raw -L build -j auto .#{all,js_jstz}
- name: Flake check
run: nix --accept-flake-config --log-format raw --log-lines 70 -L flake check -j auto
# Coverage is part of nix flake check, but we want to upload it to Codecov
# So we run it again (it's cached) and upload the result
- name: Coverage
run: nix --accept-flake-config --log-format raw -L build .#checks.x86_64-linux.cargo-llvm-cov
- name: Upload coverage to Codecov
uses: codecov/[email protected]
with:
files: result
fail_ci_if_error: true
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
build-docs:
name: Build Documentation
runs-on: ubuntu-latest
needs: [commitlint]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 18
cache: npm
- name: Get npm cache directory
id: npm-cache-dir
shell: bash
run: echo "dir=$(npm config get cache)" >> ${GITHUB_OUTPUT}
- name: Configure npm cache
uses: actions/cache@v4
id: npm-cache
with:
path: ${{ steps.npm-cache-dir.outputs.dir }}
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- run: npm ci
- name: Build with VitePress
run: npm run docs:build