生锈简化
- 作者仓库星标 0
- 作者仓库 skills-registry
- 领域
- 通用
- 作者声明的智能体
- 未找到明确声明;不据此推断已兼容或已测试
- 静态检查
- 88 / 100 · 启发式扫描,不代表运行安全
- 运行环境证据
- 未执行;当前没有隔离运行测试证据
- 作者 / 版本 / 许可证
- @tomevault-io · 未声明许可证
- 上下文用量评级
- 低消耗
- 接入复杂程度
- 即装即用
- 是否需要外部接口密钥
- 不需要
- 兼容的系统
- 未声明(默认跨平台)
- 运行环境要求
- 未检出明确要求
- 检测到的文件与系统行为
-
- 只读
- 允许写入 / 修改
- 网络行为
- 仅限本地
- 安装命令数
- 无(仅作为资料)
需要注意: 未声明工具权限范围;实际权限由运行环境决定。
# Rust Simplify
Use this skill for bounded Rust cleanup work in the Citum workspace when the task is to
improve code quality rather than fix a specific bug.
When `.jj` is present, use `docs/guides/JJ_AI_CHANGE_STACK.md` for optional
local change isolation and intent capture before publishing through Git/GitHub.
Read first:
- `docs/guides/CODING_STANDARDS.md`
- `docs/guides/AGENT_SKILLS.md`
## Target Selection
- Prefer `jcodemunch` symbol and file analysis before reading large files.
- Pick the highest-value Rust file in the affected crate or module.
- If a file path was supplied, confirm it is actually wired into the build.
## Quality Pass
- Reduce duplication and nested control flow.
- Prefer idiomatic Rust and explicit error handling.
- Review suspicious string ownership patterns. Prefer borrowed `&str` for lookup
and comparison work, and allocate `String` values at real ownership boundaries.
- Do not perform broad allocation churn in hot paths without benchmark evidence.
- Add or update tests when behavior changes.
- When tests change, keep expected values independent of current implementation
output and confirm behavior changes would have failed before the fix when
practical.
- Keep the scope to one focused file or one tightly related cluster.
## Verification
- Run the repo-required Rust checks for any `.rs`, `Cargo.toml`, or `Cargo.lock` change.
- Run `python3 scripts/audit-rust-review-smells.py --changed` for Rust cleanup
passes and review the advisory findings.
- Regenerate schemas if the touched files require it.
- Report the exact checks you ran and the result.
---
> Source: [citum/citum-core](https://github.com/citum/citum-core) — distributed by [TomeVault](https://tomevault.io).
<!-- tomevault:4.0:skill_md:2026-05-23 -->
章节与文件索引
按说明文件中的顺序排列。
目标选择
质量通行证
验证
文件/命令 -> .jj · docs/guides/JJ_AI_CHANGE_STACK.md · docs/guides/CODING_STANDARDS.md · docs/guides/AGENT_SKILLS.md · jcodemunch · &str · String · .rs
内容校验值 -> 93f7f17277fd
当前原文的自动摘译,尚未人工审校。
目标选择
在读取大文件之前,首选
jcodemunch符号和文件分析。选择受影响的板条箱或模块中价值最高的 Rust 文件。如果提供了文件路径,请确认它确实已连接到构建中。质量通行证
减少重复和嵌套控制流。更喜欢惯用的 Rust 和显式错误处理。检查可疑的字符串所有权模式。更喜欢借用
&str进行查找和比较工作,并在实际所有权边界分配String值。在没有基准证据的情况下,不要在热路径中执行广泛的分配搅动。验证
对任何
.rs、Cargo.toml或Cargo.lock更改运行 repo 所需的 Rust 检查。运行python3 scripts/audit-rust-review-smells.py --changed进行 Rust 清理并查看建议结果。如果所触及的文件需要,则重新生成架构。报告您运行的确切检查和结果。