colibri had no CI, so a non-compiling main slipped through (the build-break PR #23 had to fix) and the markdown gate from #22 was honor-system only. - .forgejo/workflows/ci.yml: runs on push-to-main + PRs. Two jobs — rust (cargo fmt --check, clippy -D warnings, cargo test --workspace) and markdown (./scripts/check-format.sh). - scripts/ci-checks.sh: same gates in one script, runnable locally before pushing (the workflow and humans share it). Validated: scripts/ci-checks.sh passes end-to-end on this branch (exit 0). NOTE: requires a registered Forgejo Actions runner with an `ubuntu-latest` label that can pull the rust/node images. Adjust runs-on to match the runner. Stacked on `all-checks-green` (the fmt fix) so the first CI run is green; merge that PR first. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
41 lines
1.3 KiB
YAML
41 lines
1.3 KiB
YAML
# Forgejo Actions CI for Colibri.
|
|
#
|
|
# Gates every push to main and every pull request on the same checks agents are
|
|
# expected to run locally (./scripts/ci-checks.sh): rustfmt, clippy, workspace
|
|
# tests, and the markdown format gate. This is what would have caught the
|
|
# build-break that PR #23 had to fix.
|
|
#
|
|
# Requirements (verify on the Forgejo instance):
|
|
# - A registered Forgejo Actions runner whose labels include `ubuntu-latest`
|
|
# (adjust `runs-on` below to match your runner's label if different).
|
|
# - The runner can pull the `rust` and `node` container images and reach
|
|
# crates.io / npm for dependencies.
|
|
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
|
|
jobs:
|
|
rust:
|
|
runs-on: ubuntu-latest
|
|
container: rust:1.95
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- name: Ensure rustfmt + clippy are present
|
|
run: rustup component add rustfmt clippy
|
|
- name: cargo fmt --check
|
|
run: cargo fmt --check
|
|
- name: cargo clippy (warnings = errors)
|
|
run: cargo clippy --workspace --all-targets -- -D warnings
|
|
- name: cargo test --workspace
|
|
run: cargo test --workspace
|
|
|
|
markdown:
|
|
runs-on: ubuntu-latest
|
|
container: node:20
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- name: Markdown format gate
|
|
run: ./scripts/check-format.sh
|