build-rust

build-rust is a skill for Claude Code, Codex from d-oit/rust-2026-template. It costs 66 tokens per session (996 once invoked), scanned B, original, MIT.

A Rust project verification workflow that checks formatting, compilation, lint warnings, tests, and documentation tests in debug and release builds. Rust is a programming language, and Cargo is its build tool.

In plain words
What is it for?
Use it to compile or check a Rust project, investigate build failures, and prepare CI build steps.
Why use it?
It brings common build and quality checks into one routine, making compiler errors, warnings, formatting issues, and test failures easier to find before release.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: installed under .agents/ (shared by several agents).

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is ./scripts/quality-gates.sh.

Good fit Use it to compile or check a Rust project, investigate build failures, and prepare CI build steps.

Compare 6 skills from other repositories ↓
Install

Getting it into your agent

It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.

Clone the repo
git clone --depth 1 https://github.com/d-oit/rust-2026-template
agentmods
npx agentmods add skills/d-oit/rust-2026-template/build-rust

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for build-rust

README.md
[![agentmods](https://agentmods.dev/badge/skills/d-oit/rust-2026-template/build-rust/github.svg)](https://agentmods.dev/skills/d-oit/rust-2026-template/build-rust)
Your own site
<a href="https://agentmods.dev/skills/d-oit/rust-2026-template/build-rust"><img src="https://agentmods.dev/badge/skills/d-oit/rust-2026-template/build-rust/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for build-rust

Your own site · 80×15
<a href="https://agentmods.dev/skills/d-oit/rust-2026-template/build-rust"><img src="https://agentmods.dev/badge/skills/d-oit/rust-2026-template/build-rust.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 66 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 996 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00066 $0.00996
Opus 5.5 $0.00026 $0.00398
Sonnet 5.5 $0.00013 $0.00199
Haiku 4.5 $0.00007 $0.00100

Measured 16d ago against content hash a19f9da5999c, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade B, and why

build-rust scanned grade B with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 16d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

**Fix**: `sudo apt-get install build-essential`
.agents/skills/build-rust/SKILL.md · 149 lines

How it starts

The opening of the file, as written. The whole thing — 149 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Skill: build-rust

Purpose

Compile, test, and verify Rust projects following 2026 best practices.

Trigger Conditions

  • When asked to build, compile, or check a Rust project
  • When CI/CD pipeline needs to run build steps
  • When investigating build failures or warnings

Prerequisites

  • Rust toolchain installed (see rust-toolchain.toml)
  • cargo available in PATH
  • WSL2 environment (optional but recommended on Windows)

Steps

0. Canonical gate (preferred)

./scripts/quality-gates.sh

This is the repository source of truth: a thin wrapper over cargo xtask quality run that selects the tier, runs the same checks as CI, and writes telemetry. Use the individual commands below for fast iteration.

1. Check (fast feedback)

cargo check --workspace --all-targets --all-features 2>&1

2. Build (debug)

cargo build --workspace --all-targets 2>&1

3. Build (release)

cargo build --workspace --release 2>&1

4. Lint with Clippy

cargo clippy --workspace --all-targets --all-features -- \
  -D warnings \
  -W clippy::pedantic \
  -W clippy::nursery \
  -A clippy::module_name_repetitions

5. Format check

cargo fmt --all -- --check

6. Run tests (with nextest)

cargo nextest run --workspace --all-features

7. Doc tests

cargo test --workspace --doc --all-features

8. Report metrics

Call metrics-reporter skill.

Success Criteria

  • cargo check exits 0 with no errors
  • cargo clippy exits 0 with -D warnings
  • cargo fmt --check exits 0
  • All tests pass
  • No unsafe blocks without // SAFETY: comments

Common Issues

Slow incremental builds in WSL2

Symptom: Build takes >30s even for small changes Fix: Ensure target/ is on the Linux filesystem, not Windows mount. See .cargo/config.toml for WSL2 disk optimization.

VS Code reloads during build

Symptom: VS Code refreshes while cargo build runs Fix: Set files.watcherExclude for **/target/** in .vscode/settings.json

Read the full file on GitHub · 149 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 16d ago Changed · +10 lines a19f9da5999c
  2. 24d ago Changed 37f4b862bdfd
  3. 2mo ago Changed · -3 lines 50a4a3c9d078
  4. 2mo ago Changed ad6a8a335b7e
  5. 3mo ago First seen · 142 lines · 66 tokens per session scan B f2941da5b89f

Subscribe to this mod's changes

build-rust is a skill published in the GitHub repository d-oit/rust-2026-template (15 stars, last pushed yesterday), licensed MIT. It adds 66 tokens to every session and 996 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it B with 1 finding (asks for root). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

build-rust compared with skills from other repositories

build-rust next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
build-rustd-oit/rust-2026-templateSkill15yesterdayMITB66Claude Code, Codex
review-backendAndreiBozantan/svelte-axum-templateSkill22mo agoMITA54Claude Code, Codex
yada-yada-yadaAndreiBozantan/svelte-axum-templateSkill22mo agoMITA81Claude Code, Codex
fix-issueAndreiBozantan/svelte-axum-templateSkill22mo agoMITA65Claude Code, Codex
review-frontendAndreiBozantan/svelte-axum-templateSkill22mo agoMITA62Claude Code, Codex
make-it-soAndreiBozantan/svelte-axum-templateSkill22mo agoMITA55Claude Code, Codex
triage-review-findingAndreiBozantan/svelte-axum-templateSkill22mo agoMITA59Claude Code, Codex