Claude-skill-registry csharp-project-expert
ALWAYS use for ANY C# operation: renaming (files/classes/methods/properties/namespaces), finding references/usages ("where is X used"), finding definitions ("where is X defined"), understanding code structure (hierarchies/dependencies/relationships). Roslyn-powered semantic analysis ensures all references are updated correctly across the entire solution.
install
source · Clone the upstream repo
git clone https://github.com/majiayu000/claude-skill-registry
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/majiayu000/claude-skill-registry "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/data/csharp-project-expert" ~/.claude/skills/majiayu000-claude-skill-registry-csharp-project-expert && rm -rf "$T"
manifest:
skills/data/csharp-project-expert/SKILL.mdsource content
C# Project Expert
Compiler-accurate semantic analysis for C# using Roslyn APIs. Not text search - understands C# semantics.
When to Use
Use this skill for:
- Finding symbol definitions (classes, methods, interfaces, properties)
- Finding all references before refactoring
- Safe renaming across entire solution (always preview first!)
- Understanding method signatures and type hierarchies
- Checking compilation errors/warnings
- Finding interface implementations
- Analyzing method call chains (callers/callees)
- Finding unused code
Don't use for: Non-C# files, simple text/comment searches, projects without .sln/.csproj
CLI Path (Cross-Platform)
| Platform | Path |
|---|---|
| Linux x64 | |
| macOS x64 | |
| macOS ARM | |
| Windows x64 | |
Command Syntax
<cli-path> [-s <solution.sln> | -p <project.csproj>] [-o json|text|markdown] <command> [options]
Auto-Discovery: If
-s or -p is not specified, the tool automatically searches the current directory for a .sln file (preferred) or .csproj file.
All Commands (18)
| Command | Purpose | Key Options |
|---|---|---|
| Where is symbol defined | `--type class |
| All usages of symbol | , |
| Rename across solution | (use first!), , |
| Method/type signature | , |
| Members of a type | `--kind method |
| Compilation errors/warnings | `--severity error |
| Verify symbol exists | |
| Interface implementations | - |
| Type hierarchy | `--direction ancestors |
| Who calls this method | - |
| What does method call | - |
| Type/file dependencies | - |
| Find dead code | - |
| Extract interface | - |
| Generate stubs | - |
| Types in namespace/file | |
| Namespace hierarchy | - |
| Quick file analysis | - |
Critical Workflows
Safe Rename (Always Follow)
- Check usage:
find-references OldName --type method - Preview changes (REQUIRED):
rename OldName NewName --type method --preview - Apply:
rename OldName NewName --type method - When renaming classes/types: Add
to also rename the file--rename-file - Verify:
diagnostics --severity error
Understand Unknown Code
- What is it?
find-definition ClassName --type class - What can it do?
list-members ClassName - How does it fit?
inheritance-tree ClassName - What does it need?
dependencies ClassName
Output Formats
(default) - Machine-readablejson
- Human-readable terminaltext
- Documentation formatmarkdown
Requirements
- .NET 10.0 runtime
- Valid .sln or .csproj file
- Solution must compile
Exit Codes
Success |0
Error |1
Not found2
Detailed References
- COMMANDS.md - Full command reference
- WORKFLOWS.md - Step-by-step workflows
- EXAMPLES.md - Real-world scenarios