Command Palette

Search for a command to run...

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

dotnet-project-analysis

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

Navigating .NET solution structure or build configuration. Analyzes .sln, .csproj, CPM.

wshaddixот wshaddix★ 94 звезды на GitHub

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


dotnet-project-analysis

Analyzes .NET solution structure, project references, and build configuration. This skill is foundational -- agents need to understand project layout before doing any meaningful .NET development work.

Prerequisites: Run [skill:dotnet-version-detection] first to determine TFM and SDK version. For .NET 10+ single-file apps without a .csproj, see [skill:dotnet-file-based-apps] instead.


Step 1: Find the Solution Root

Look for solution files in the workspace, starting from the current directory and walking up to the repository root.

.sln (Legacy Format)

The traditional MSBuild solution format. Contains project paths and build configurations.

Microsoft Visual Studio Solution File, Format Version 12.00
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MyApp", "src\MyApp\MyApp.csproj", "{GUID}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MyApp.Tests", "tests\MyApp.Tests\MyApp.Tests.csproj", "{GUID}"
EndProject

Extract project entries from Project("...") lines. The second quoted value is the project name, the third is the relative path to the .csproj.

.slnx (Modern XML Format)

The new XML-based solution format (supported in .NET 10+ SDK, Visual Studio 17.13+). Preferred for new projects.

<Solution>
  <Folder Name="/src/">
    <Project Path="src/MyApp/MyApp.csproj" />
  </Folder>
  <Folder Name="/tests/">
    <Project Path="tests/MyApp.Tests/MyApp.Tests.csproj" />
  </Folder>
</Solution>

Extract project entries from <Project Path="..." /> elements. Solution folders (<Folder>) indicate logical grouping.

No Solution File

If no .sln or .slnx is found, scan for .csproj files recursively. Report: "No solution file found. Discovered N project files. Consider creating a solution with dotnet new sln and dotnet sln add."


Step 2: Analyze Each Project

For every .csproj discovered in Step 1, read its contents and extract the following.

Project SDK and Type

The <Project Sdk="..."> attribute identifies the project kind:

SDK Project Type Description
Microsoft.NET.Sdk Class Library / Console Default SDK, check for <OutputType>
Microsoft.NET.Sdk.Web Web (API / MVC / Razor Pages) ASP.NET Core web application
Microsoft.NET.Sdk.BlazorWebAssembly Blazor WASM Client-side Blazor (legacy SDK)
Microsoft.NET.Sdk.Worker Worker Service Background service / daemon
Microsoft.NET.Sdk.Razor Razor Class Library Shared Razor components
Microsoft.Maui.Sdk or TFMs with -android/-ios MAUI Cross-platform mobile/desktop
Custom or Uno.Sdk Uno Platform Cross-platform UI (check for Uno references)

Output Type Detection

If SDK is Microsoft.NET.Sdk, check <OutputType> to distinguish:

OutputType Meaning
Exe Console application
Library (or absent) Class library
WinExe Windows desktop (WPF/WinForms/WinUI)

Test Project Detection

A project is a test project if any of the following are true:

  • <IsTestProject>true</IsTestProject> is set
  • Has a PackageReference to xunit.v3, xunit, NUnit, MSTest.TestFramework, or Microsoft.NET.Test.Sdk
  • Project name ends with .Tests, .UnitTests, .IntegrationTests, or .TestUtils

Blazor Project Detection

A project is Blazor if:

  • SDK is Microsoft.NET.Sdk.BlazorWebAssembly
  • Has <PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" />
  • Has .razor files in the project directory
  • Uses AddInteractiveServerComponents() or AddInteractiveWebAssemblyComponents() in startup

MAUI Project Detection

A project is MAUI if:

  • <UseMaui>true</UseMaui> is set
  • SDK is Microsoft.Maui.Sdk
  • TFM includes platform-specific targets: net*-android, net*-ios, net*-maccatalyst, net*-windows (e.g., net8.0-android, net10.0-ios)

Uno Platform Detection

A project is Uno Platform if:

  • SDK is Uno.Sdk or Uno.Sdk.Private
  • Has PackageReference to Uno.WinUI or Uno.UI
  • TFM includes Uno-specific targets (e.g., net*-browserwasm, net*-desktop)

Step 3: Map Project References

Read <ProjectReference> elements from each .csproj to build the dependency graph.

<ItemGroup>
  <ProjectReference Include="..\MyApp.Core\MyApp.Core.csproj" />
  <ProjectReference Include="..\MyApp.Infrastructure\MyApp.Infrastructure.csproj" />
</ItemGroup>

Build a dependency graph and report it:

Project Dependency Graph
========================
MyApp.Web (Web API)
  -> MyApp.Core (Library)
  -> MyApp.Infrastructure (Library)
    -> MyApp.Core (Library)
MyApp.Tests (Test)
  -> MyApp.Web (Web API)
  -> MyApp.Core (Library)

Flag issues:

  • Circular references: "Project A -> B -> A detected. This will cause build failures."
  • **Test pr
Полный SKILL.md на GitHub

Установить dotnet-project-analysis в Claude Code и Claude Desktop

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

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

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

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

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

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

FAQ

Что делает скилл dotnet-project-analysis?

Navigating .NET solution structure or build configuration. Analyzes .sln, .csproj, CPM.

Как установить скилл dotnet-project-analysis?

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

Скилл dotnet-project-analysis запускает скрипты?

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

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

Сравнить dotnet-project-analysis с