Skip to main content

analyze-code

Run repository code analysis as a final check after completing prompts, targeting every changed Rust package by PackageNames.

来源信息

仓库
Azure/azure-sdk-for-rust
最近来源活动
2026年9月16日 22:53
检测到的 SKILL.md 语言
英语
星标
886
分支
370

安装方式

默认使用会先检查来源的 Prompt;你也可以切换为直接命令,或下载本地副本。

检查来源文件

决定是否安装前,请先阅读 SKILL.md,以及 SkillsMP 当前展示的配套文件。

正在显示 SKILL.md

SKILL.md
来源说明 · 只读预览
name
analyze-code
description
Run repository code analysis as a final check after completing prompts, targeting every changed Rust package by PackageNames.
# Analyze changed packages Run this as a final check after completing any prompt that changes repository files. 1. Collect changed files from Git, including staged, unstaged, untracked, and deleted files: ```bash { git diff --staged --name-only; git diff --name-only; git ls-files --others --exclude-standard -- 'sdk'; } | sort -u ``` 2. Assume service crates live under `sdk/<service-directory>/<crate-name>`. For each changed file under `sdk/`, derive the candidate crate directory from the first three path segments and keep it only when `<crate-directory>/Cargo.toml` exists. Include any crate names specified in the prompt, then collect and deduplicate all `<crate-name>` values as package names. 3. Run the analyzer once from the repository root with all changed package names: ```powershell ./eng/scripts/Analyze-Code.ps1 -PackageNames @('<crate-name-1>', '<crate-name-2>') ``` If neither changed files nor the prompt identify a service crate, report that no packages need analysis. Otherwise, report the packages analyzed and any failures.
在 GitHub 查看