Skip to content

gha: add basic lint & build jobs #7

gha: add basic lint & build jobs

gha: add basic lint & build jobs #7

Workflow file for this run

name: CI
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- name: Builder
run: docker build -t builder -f Dockerfile.actions .
- name: Cargo fmt
run: |
docker run --rm \
-v "${{ github.workspace }}:/workspace" \
-e RUSTFLAGS="-Dwarnings" \
-w /workspace \
builder \
bash -c "
cargo fmt --check && \
cargo clippy
"
build:
runs-on: ubuntu-latest
needs: [lint]
steps:
- uses: actions/checkout@v5
- name: Builder
run: docker build -t builder -f Dockerfile.actions .
- name: Builder
run: |
docker run --rm \
-v "${{ github.workspace }}:/workspace" \
-e RUSTFLAGS="-Dwarnings" \
-w /workspace \
builder \
bash -c "
cargo build
"