Some checks failed
CI / check (push) Failing after 1m30s
actions/checkout is a Node action and the rust:* container has no node, so its post-step failed with 'node: not found'. Use node:20-bookworm (node present for checkout) and install Rust via rustup, running build, clippy, and test in one shell.
28 lines
875 B
YAML
28 lines
875 B
YAML
# Build, lint, and test on every push and pull request. Adjust `runs-on` to a
|
|
# label your Forgejo runner advertises (commonly `ubuntu-latest` or `docker`).
|
|
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
|
|
jobs:
|
|
check:
|
|
runs-on: ubuntu-latest
|
|
# A Node image, because the JS-based actions/checkout needs `node` in the
|
|
# container. Rust is installed on top; a rust:* image has no node.
|
|
container:
|
|
image: node:20-bookworm
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Build, lint, and test
|
|
run: |
|
|
set -e
|
|
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal -c clippy
|
|
. "$HOME/.cargo/env"
|
|
cargo build --workspace --locked
|
|
cargo clippy --workspace --locked -- -D warnings
|
|
cargo test --workspace --locked
|