Skip to content

Commit de83376

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 ef523e0 commit de83376

1 file changed

Lines changed: 16 additions & 49 deletions

File tree

.github/workflows/rust-ci.yml

Lines changed: 16 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -1,53 +1,20 @@
1-
# SPDX-License-Identifier: MPL-2.0-or-later
1+
# SPDX-License-Identifier: MPL-2.0
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.
25
name: Rust CI
3-
on: [push, pull_request]
4-
env:
5-
CARGO_TERM_COLOR: always
6-
RUSTFLAGS: -Dwarnings
76

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

30-
security:
31-
runs-on: ubuntu-latest
32-
steps:
33-
- uses: actions/checkout@v6.0.2
34-
- uses: dtolnay/rust-toolchain@stable
35-
- name: Install cargo-audit
36-
run: cargo install cargo-audit
37-
- name: Security audit
38-
run: cargo audit
39-
- name: Check for outdated deps
40-
run: cargo install cargo-outdated && cargo outdated --exit-code 1 || true
12+
permissions:
13+
contents: read
4114

42-
coverage:
43-
runs-on: ubuntu-latest
44-
steps:
45-
- uses: actions/checkout@v6.0.2
46-
- uses: dtolnay/rust-toolchain@stable
47-
- name: Install tarpaulin
48-
run: cargo install cargo-tarpaulin
49-
- name: Generate coverage
50-
run: cargo tarpaulin --out Xml
51-
- uses: codecov/codecov-action@v6
52-
with:
53-
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)