chore: update ontoref ci adr 0014

This commit is contained in:
Jesús Pérez 2026-04-09 00:03:59 +01:00
parent 75e5ebd9a2
commit 9e6e816ebc
Signed by: jesus
GPG key ID: 9F243E355E0BC939
6 changed files with 93 additions and 62 deletions

7
.config/nextest.toml Normal file
View file

@ -0,0 +1,7 @@
[profile.ci-test]
fail-fast = true
retries = 0
[profile.ci]
fail-fast = false
retries = 1

43
.ontology/workflow.ncl Normal file
View file

@ -0,0 +1,43 @@
let W = import "../reflection/schemas/workflow.ncl" in
let D = import "../reflection/defaults/workflow.ncl" in
{
layers = [
{
id = "commit-fast",
trigger = 'OnCommit,
validations = [
"rust-fmt",
"rust-clippy",
"nextest-ci-test",
"deny-subset",
"manifest-coverage",
],
builds = [],
distributions = [],
providers = [W.pre_commit "pre-commit"],
},
{
id = "ci-standard",
trigger = 'OnPR,
validations = [
"rust-clippy-all",
"nextest-ci",
"deny-subset",
"nickel-typecheck",
"nushell-check",
],
builds = ["release-native"],
distributions = [],
providers = [
W.woodpecker ".woodpecker/ci.yml",
W.justfile "ci-standard",
],
},
],
validations = D.validations,
builds = D.builds,
distributions = {},
}

View file

@ -6,7 +6,7 @@
log = {
level = "info",
path = ".ontoref/logs",
path = ".ontoref/logs/actions.jsonl",
rotation = "daily",
compress = false,
archive = ".ontoref/logs/archive",

View file

@ -15,3 +15,12 @@
{"ts":"2026-03-14T18:29:31+0000","author":"unknown","actor":"agent","level":"read","action":"describe capabilities"}
{"ts":"2026-03-14T18:29:32+0000","author":"unknown","actor":"agent","level":"read","action":"constraint"}
{"ts":"2026-03-14T23:56:57+0000","author":"unknown","actor":"agent","level":"read","action":"adr list"}
{"test": 1}
{"ts":"2026-04-08T22:52:37+0100","author":"unknown","actor":"agent","level":"read","action":"migrate pending"}
{"ts":"2026-04-08T22:54:36+0100","author":"unknown","actor":"developer","level":"read","action":"migrate pending"}
{"ts":"2026-04-08T22:55:11+0100","author":"unknown","actor":"agent","level":"read","action":"migrate pending"}
{"ts":"2026-04-08T22:58:49+0100","author":"unknown","actor":"agent","level":"read","action":"migrate show 0014"}
{"ts":"2026-04-08T23:00:03+0100","author":"unknown","actor":"agent","level":"read","action":"migrate pending"}
{"ts":"2026-04-08T23:00:07+0100","author":"unknown","actor":"agent","level":"read","action":"migrate list"}
{"ts":"2026-04-08T23:00:55+0100","author":"unknown","actor":"agent","level":"write","action":"workflow generate"}
{"ts":"2026-04-08T23:01:00+0100","author":"unknown","actor":"agent","level":"read","action":"workflow validate"}

View file

@ -1,84 +1,45 @@
# Woodpecker CI Pipeline
# Equivalent to GitHub Actions CI workflow
# Generated by dev-system/ci
# Generated by ore workflow generate — layer: ci-standard
# Source: .ontology/workflow.ncl
# Do not edit manually — regenerate with: ore workflow generate --layer ci-standard
when:
event: [push, pull_request, manual]
branch:
- main
- develop
steps:
# === LINTING ===
lint-rust:
rust-clippy-all:
image: rust:latest
commands:
- curl --proto '=https' --tlsv1.2 -sSf https://just.systems/install.sh | bash -s -- --to /usr/local/bin
- rustup component add clippy
- cargo fmt --all -- --check
- cargo clippy --all-targets -- -D warnings
- cargo clippy --all-targets --all-features -- -D warnings
lint-bash:
image: koalaman/shellcheck-alpine:stable
commands:
- apk add --no-cache curl bash
- find . -name '*.sh' -type f ! -path './target/*' -exec shellcheck {} +
lint-nickel:
nickel-typecheck:
image: rust:latest
commands:
- cargo install nickel-lang-cli --locked
- find . -name '*.ncl' -type f ! -path './target/*' -exec nickel typecheck {} \;
- nickel typecheck
lint-nushell:
nushell-check:
image: rust:latest
commands:
- cargo install nu --locked
- find . -name '*.nu' -type f ! -path './target/*' -exec nu --ide-check 100 {} \;
- find . -name '*.nu' ! -path '*/target/*' -print0 | xargs -0 -I\{\} nu --ide-check 100 \{\}
lint-markdown:
image: node:alpine
commands:
- npm install -g markdownlint-cli2
- markdownlint-cli2 '**/*.md' '#node_modules' '#target'
# === TESTING ===
test:
nextest-ci:
image: rust:latest
commands:
- cargo test --workspace --all-features
depends_on:
- lint-rust
- lint-bash
- lint-nickel
- lint-nushell
- lint-markdown
- cargo install cargo-nextest --locked
- cargo nextest run --all-features --workspace --profile ci --cargo-profile ci
depends_on: ["rust-clippy-all", "nickel-typecheck", "nushell-check"]
environment:
RUST_BACKTRACE: 1
# === BUILD ===
build:
image: rust:latest
commands:
- cargo build --release
depends_on:
- test
# === SECURITY ===
security-audit:
image: rust:latest
commands:
- cargo install cargo-audit --locked
- cargo audit --deny warnings
depends_on:
- lint-rust
license-check:
deny-subset:
image: rust:latest
commands:
- cargo install cargo-deny --locked
- cargo deny check licenses advisories
depends_on:
- lint-rust
build-release-native:
image: rust:latest
commands:
- cargo build --release --workspace
depends_on: ["rust-clippy-all", "nickel-typecheck", "nushell-check"]

11
justfiles/workflow.just Normal file
View file

@ -0,0 +1,11 @@
# Generated by ore workflow generate
# Source: .ontology/workflow.ncl
# layer: ci-standard
ci-standard:
cargo clippy --all-targets --all-features -- -D warnings
cargo nextest run --all-features --workspace --profile ci --cargo-profile ci
cargo deny check licenses advisories
nickel typecheck
nu --ide-check 100
cargo build --release --workspace