coding-guidelines
✓在询问 Rust 代码风格或最佳实践时使用。关键词:命名、格式化、注释、clippy、rustfmt、lint、代码风格、最佳实践、P.NAM、G.FMT、代码审查、命名约定、变量命名、函数命名、类型命名、命名规范、代码风格、格式化、最佳实践、代码审查、怎么命名
SKILL.md
| No get prefix | fn name() not fn getname() | | Iterator convention | iter() / itermut() / intoiter() | | Conversion naming | as (cheap &), to (expensive), into (ownership) | | Static var prefix | GCONFIG for static, no prefix for const |
| Use newtypes | struct Email(String) for domain semantics | | Prefer slice patterns | if let [first, .., last] = slice | | Pre-allocate | Vec::withcapacity(), String::withcapacity() | | Avoid Vec abuse | Use arrays for fixed sizes |
| Prefer bytes | s.bytes() over s.chars() when ASCII | | Use Cow | When might modify borrowed data | | Use format! | Over string concatenation with + | | Avoid nested iteration | contains() on string is O(nm) |
可引用信息
为搜索与 AI 引用准备的稳定字段与命令。
- 安装命令
npx skills add https://github.com/zhanghandong/rust-skills --skill coding-guidelines- 分类
- </>开发工具
- 认证
- ✓
- 收录时间
- 2026-02-01
- 更新时间
- 2026-02-18
快速解答
什么是 coding-guidelines?
在询问 Rust 代码风格或最佳实践时使用。关键词:命名、格式化、注释、clippy、rustfmt、lint、代码风格、最佳实践、P.NAM、G.FMT、代码审查、命名约定、变量命名、函数命名、类型命名、命名规范、代码风格、格式化、最佳实践、代码审查、怎么命名 来源:zhanghandong/rust-skills。
如何安装 coding-guidelines?
打开你的终端或命令行工具(如 Terminal、iTerm、Windows Terminal 等) 复制并运行以下命令:npx skills add https://github.com/zhanghandong/rust-skills --skill coding-guidelines 安装完成后,技能将自动配置到你的 AI 编程环境中,可以在 Claude Code 或 Cursor 中使用
这个 Skill 的源码在哪?
https://github.com/zhanghandong/rust-skills
详情
- 分类
- </>开发工具
- 来源
- skills.sh
- 收录时间
- 2026-02-01