velesnitski

Rtk Rust Safety Net — Development skill for Claude Code

Development community

Defensive idioms when generating Rust code.

How to install Rtk Rust Safety Net

Installs to ~/.claude/commands/velesnitski-rtk-rtk-rust-safety-net.md

Terminal
mkdir -p ~/.claude/commands && curl -fsSL https://raw.githubusercontent.com/velesnitski/rtk/HEAD/.claude/commands/rtk-rust-safety-net.md -o ~/.claude/commands/velesnitski-rtk-rtk-rust-safety-net.md

Restart Claude Code, or start a new session, for it to be picked up.

What Rtk Rust Safety Net does

Defensive idioms when generating Rust code.

Rust safety net

When writing Rust:

  • Avoid .unwrap() and .expect() outside of tests, build scripts, and at-startup code where a panic IS the failure mode. In every other path return Result (custom error or anyhow::Error).
  • clone() is acceptable in glue code; in hot paths, prefer &str over String and slice references over Vec clones.
  • unsafe requires a SAFETY comment immediately above explaining why the invariants

Alternatives in Development

  • /diagnose — Vérifie l'état de l'environnement RTK et suggère des corrections 25.5k ★
  • Doctor — Environment diagnostics with interactive fixes — providers, auth, RTK, hooks, token optimization 2.8k ★
  • /autopilot — Autonomous hunt loop with deterministic scope safety and configurable checkpoints 1.2k ★

Full documentation available on GitHub

View Source Repository