Skip to content

Commit d6136a3

Browse files
hyperpolymathclaude
andcommitted
ci(rust): convert rust-ci.yml to thin wrapper (standards#174)
Replaces the per-repo `rust-ci.yml` copy with a 5-line wrapper invoking the shared reusable workflow in `hyperpolymath/standards` (PR #174). Pinned to PR #174's HEAD SHA `4fdf4314b4ab54269adbaff10e30e483b5e86845`; will resolve to standards/main once #174 merges. Estate audit found ~87 rust-ci.yml copies across the estate; this is one of them. The reusable provides identical cargo check/clippy/fmt/test behaviour with opt-in `enable_audit` + `enable_coverage` inputs. Pattern precedent: standards#168 (governance-reusable) + downstream wrappers absolute-zero#41 + tma-mark2#41. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent a728f33 commit d6136a3

1 file changed

Lines changed: 15 additions & 51 deletions

File tree

.github/workflows/rust-ci.yml

Lines changed: 15 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -1,56 +1,20 @@
11
# SPDX-License-Identifier: MPL-2.0
2-
permissions:
3-
contents: read
4-
2+
# Rust CI — thin wrapper calling the shared estate reusable in
3+
# hyperpolymath/standards. Configure once, propagate everywhere.
4+
# See: docs/CI-REUSABLE-WORKFLOWS.adoc in standards.
55
name: Rust CI
6-
on: [push, pull_request]
7-
env:
8-
CARGO_TERM_COLOR: always
9-
RUSTFLAGS: -Dwarnings
106

11-
jobs:
12-
test:
13-
runs-on: ubuntu-latest
14-
steps:
15-
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
16-
- uses: dtolnay/rust-toolchain@4be9e76fd7c4901c61fb841f559994984270fce7 # stable
17-
with:
18-
components: rustfmt, clippy
19-
- uses: Swatinem/rust-cache@779680da715d629ac1d338a641029a2f4372abb5 # v2
20-
21-
- name: Check formatting
22-
run: cargo fmt --all -- --check
23-
24-
- name: Clippy lints
25-
run: cargo clippy --all-targets --all-features -- -D warnings
26-
27-
- name: Run tests
28-
run: cargo test --all-features
29-
30-
- name: Build release
31-
run: cargo build --release
7+
on:
8+
push:
9+
branches: [main, master]
10+
pull_request:
3211

33-
security:
34-
runs-on: ubuntu-latest
35-
steps:
36-
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
37-
- uses: dtolnay/rust-toolchain@4be9e76fd7c4901c61fb841f559994984270fce7 # stable
38-
- name: Install cargo-audit
39-
run: cargo install cargo-audit
40-
- name: Security audit
41-
run: cargo audit
42-
- name: Check for outdated deps
43-
run: cargo install cargo-outdated && cargo outdated --exit-code 1 || true
12+
permissions:
13+
contents: read
4414

45-
coverage:
46-
runs-on: ubuntu-latest
47-
steps:
48-
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
49-
- uses: dtolnay/rust-toolchain@4be9e76fd7c4901c61fb841f559994984270fce7 # stable
50-
- name: Install tarpaulin
51-
run: cargo install cargo-tarpaulin
52-
- name: Generate coverage
53-
run: cargo tarpaulin --out Xml
54-
- uses: codecov/codecov-action@ab904c41d6ece82784817410c45d8b8c02684457 # v3
55-
with:
56-
files: cobertura.xml
15+
jobs:
16+
rust-ci:
17+
uses: hyperpolymath/standards/.github/workflows/rust-ci-reusable.yml@4fdf4314b4ab54269adbaff10e30e483b5e86845
18+
with:
19+
enable_audit: true
20+
enable_coverage: true

0 commit comments

Comments
 (0)