Skip to content

YET MOAR

YET MOAR #89

Workflow file for this run

name: CI
on:
push:
branches: [main]
# Don't run tests when only text files/docs/etc. were modified
paths-ignore:
- "COPYRIGHT"
- "LICENSE-*"
- "**.md"
- "**.txt"
pull_request:
branches: [main]
# Don't run tests when only text files/docs/etc. were modified
# TODO: this will need to be updated for handling different sub-parts of the
# build when I have both "build `lx`" and "use `lx` to build the site" as
# part of the same repo (assuming that is indeed what I do).
paths-ignore:
- "COPYRIGHT"
- "LICENSE-*"
- "**.md"
- "**.txt"
env:
CARGO_TERM_COLOR: always
jobs:
lint:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./lx
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Rust
uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: stable
components: clippy, rustfmt
- name: Check formatting
run: cargo fmt --all --quiet -- --check
- name: Lint with clippy
run: cargo clippy --no-deps
build:
runs-on: ubuntu-latest
needs: lint
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up cargo
uses: actions-rust-lang/setup-rust-toolchain@v1
- name: Build
run: cargo build --verbose
- name: Run tests
run: cargo test --verbose