Rust Configs & Rules
Claude Code configurations for Rust projects.
Rulerust
Coding Guidelines Rule
- **Dependencies**: Use `default_features = false`; be conservative adding new deps - **Error handling**: Don't use `if let Ok` without a comment explaining why it's safe - **Patches**: Don't use `patch.crates-io` for SDK crates; use git references instead - **Feature gates**: Don't feature-gate...
455000
Rulerust
Compiler Rule
- LSP integration: You have access to `rust-analyzer`. Before refactoring, use "Go to Definition" or "Hover" to confirm type signatures, and rely as much as possible on deterministic refactors (e.g. use rust analyzer to rename.) - Diagnostics: Always check for compiler warnings/errors after writing...
379000
Rulerust
Quality Commands Rule
```bash
354000
Rulerust
Development Guidelines Rule
1. **NEVER use mock frameworks or mock code:** - FORBIDDEN: `mockall`, `mock` libraries, or any mock implementations - FORBIDDEN: Mock structs, mock functions, or fake implementations - ALLOWED: Real integration tests with temporary files/directories - ALLOWED: Testing with actual data structures...
354000
Rulerust
Comments Rule
168000
Rulerust
Tss Submit Rule
10000
Rulerust
Yagni Principle Rule
Do not add speculative features or future-proofing unless explicitly required.
9000
Rulerust
Conversational Interaction Rule
When asking questions, use a conversational form-based experience.
9000
Rulerust
Documentation Protocols Rule
Documentation must be synchronised with code changes—no outdated references.
9000
Rulerust
.Mcp.Json.Bak Rule
{ "mcpServers": { "memory": { "type": "stdio", "command": "env", "args": [ "MEMORY_FILE_PATH=/home/v/project/centotype/.mcp-memory/memory.json", "npx", "-y", "@modelcontextprotocol/server-memory" ], "env": {} } } }
5000
Rulerust
Tool Selection Rule
1. **Searching for code by intent** - `code(action="search", query="authentication")` finds auth code even if the word "authentication" isn't used 2. **Understanding file structure** - `code(action="symbols", file_path="file.rs")` lists all definitions 3. **Tracing call relationships** -...
3000
Rulerust
Typeck Rule
paths: **/typeck/**
2000
Rulerust
Types Rule
paths: **/ori_types/**
2000