Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

msbuild

БесплатноБез исполняемых скриптовНе проверен

Use before MSBuild custom-target or incremental-generation repairs, XML/import/hook review, .binlog capture/replay, or assessing supported/unsupported…

dotnetот dotnet★ 6 430 звёзд на GitHub

Об этом скилле

MSBuild troubleshooting

For advice or static review, answer from the supplied XML, package facts, or measurements when they settle the question: no reference reads, checkout discovery, commands, or invented verification. For requested work, start at the supplied project or artifact; discover only what the next decision needs. Read a reference only for a specific unresolved question. References are not invocable skills.

Start with the task and evidence

Before editing, follow repository instructions and inspect the project/imports. Preserve the original command, working directory, SDK, configuration, target framework, runtime identifier, global properties, and target. Ask only for consequential information that cannot be discovered.

An existing .binlog can be the only available artifact. Analyze it before requesting a new build; paths inside it do not prove a checkout exists locally.

For a mixed request, fix correctness before measuring successful builds, and keep authoring review separate from a performance experiment. A failing test assertion after a successful build is not an MSBuild failure.

Capture only: choose an unused artifact path under the supplied workspace, unless the user specified another artifact directory. Do not put the only deliverable in a shared/global temporary directory where workspace artifact collection will miss it, or stage/commit the log. Append the binary logger to the exact supplied command, run it once, and save its original exit code before checking the new log is nonempty. Report the artifact path and original exit code, then stop: no replay, diagnosis, or repair. Read capture details only for an unresolved wrapper, logger-option, toolset, or privacy question.

1. Troubleshoot build issues

Goal: identify the independent root causes and make the smallest repair, not a broad cleanup.

Situation Reference if needed Action
A build failed and a binary log exists binlog-failure-analysis Replay the log with MSBuild; connect errors to the responsible project instance, target, and task. Separate root causes from cascading failures.
The failure needs evidence and no matching log exists binlog-generation, then failure analysis Capture the original invocation once and verify the artifact. Analyze it only when requested.
A project/build file has incorrect conditions, items, properties, or output paths msbuild-antipatterns Select the relevant catalog entries and check their exceptions before changing anything.
Imports or build hooks are missing, overwritten, or run in the wrong order extension-points Inspect the import contract, discovery order, and packed NuGet layout rather than hiding a required failure.
Outputs are stale or required work is skipped incremental-build Track input-set membership as well as file timestamps; apply the repair contract below.

For build-wiring-only work, generator and source inputs are read-only throughout, not restored after tests; edit the original only as the requested repair requires. Allocate disposable scratch as a uniquely named directory outside the project tree, normally the OS temporary directory from mktemp -d; a copy inside the project can be matched by SDK default globs and break the later confirming build. Print the path once and write every copy, log, and hash under it: no fixed leaf names, pointer files, pre-deleting, or globbing to recover it. After the checks, remove exactly that path (never a pattern) and keep it in the report. Copy the project/input tree and required imports; run every scenario that adds, deletes, empties, or retimes inputs, or deletes obj/outputs, with the copy as working directory. A backup is not a verification copy, nor is an original project already under a temporary path. Compare original hashes before/after; equal final hashes do not excuse intermediate mutation. A confirming build of the repaired original must not delete outputs. If the copy cannot reproduce the environment, report blocked checks.

For input-set changes, prefer a persisted membership list written with WriteLinesToFile and WriteOnlyWhenDifferent, plus actual files in Inputs. A path list is not a content hash. Verify first/unchanged builds, deletion, older addition, empty inputs, and missing-output recovery on the copy. End the repair report, however brief, with three labeled explanations, not only a checklist:

  • Cause: state both blind spots: a deleted input vanishes from the timestamp comparison; an added input older than the output never looks newer; either skips required regeneration.
  • Mechanism: identify the membership artifact and how its changes invalidate the output
Полный SKILL.md на GitHub

Установить msbuild в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

references/antipatterns/additional-antipatterns.mdreferences/antipatterns/incremental-build-inputs-outputs.mdreferences/antipatterns/private-assets.mdreferences/binlog-failure-analysis.mdreferences/binlog-generation.mdreferences/build-perf-baseline.mdreferences/build-perf-diagnostics.mdreferences/copy-to-output-directory.mdreferences/eval-performance.mdreferences/extension-points.mdreferences/incremental-build.mdreferences/msbuild-antipatterns.md

FAQ

Что делает скилл msbuild?

Use before MSBuild custom-target or incremental-generation repairs, XML/import/hook review, .binlog capture/replay, or assessing supported/unsupported build-speedup claims and controlled timings, even without a checkout. For MSBuild authoring itself, activate before reviewing/editing .proj/.props/.targets/.csproj/.fsproj/.vbproj or Directory.Build files, including no-change import reviews. Framework/API/.NET/ASP.NET upgrade plans and working non-SDK-to-SDK/packages.config conversions are migrations, even if they mention .csproj/NuGet: DO NOT activate. A failing assertion after a successful build is code/test debugging: DO NOT activate. Check Import/Exists, required and NuGet build/buildTransitive/nuspec imports, conditions, Inputs/Outputs, stale outputs and incorrect skips. Build checks use copies; source inputs stay read-only. Diagnose failed dotnet build/restore/pack/publish or slow evaluation/compilation/copying. Exclude SDK installation alone, C# refactoring, runtime CPU profiling and non-MSBuild builds.

Как установить скилл msbuild?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл msbuild запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить msbuild с