new-library
Automates scaffolding for packable, reusable .NET libraries.
Install
mkdir -p .claude/skills/new-library && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/10719" && unzip -o skill.zip -d .claude/skills/new-library && rm skill.zipInstalls to .claude/skills/new-library
Activation
This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.
Scaffold a new reusable .NET library with correct naming, multi-targeting, and structure. Use when: creating a new library project, adding a reusable package, setting up a shared library under src/.Key capabilities
- →Scaffold new .NET libraries
- →Apply naming conventions
- →Configure multi-targeting
- →Set up test projects
How it works
The skill scaffolds a new .NET library with the correct namespace, multi-targeting, and directory structure, following established naming conventions.
Inputs & outputs
When to use new-library
- →Creating a new reusable library
- →Setting up shared components
- →Adding a new NuGet-packable project
- →Standardizing internal .NET structure
About this skill
New Library
When to Use
- Creating a new reusable, packable library under
src/ - Adding a shared component meant for NuGet distribution
Naming Convention
Libraries use a {Domain}.{Feature} pattern. The Kritikos. root namespace prefix is applied automatically by Directory.Build.props.
| Domain prefix | When to use | Example |
|---|---|---|
AspNetCore.{Feature} | Depends on Microsoft.AspNetCore.App | AspNetCore.ProblemDetails |
Extensions.{Feature} | Framework-agnostic, depends only on Microsoft.Extensions.* | Extensions.Hashing |
EntityFrameworkCore.{Feature} | Depends on EF Core | EntityFrameworkCore.Auditing |
| (no prefix) | Pure .NET with no framework dependency | Primitives |
Always propose 2–4 name options to the user and allow a custom choice.
Multi-Targeting
Target both current LTS versions plus optionally one STS version if newer than the latest LTS:
| Scenario | Targets | Rationale |
|---|---|---|
| .NET 10 is current LTS | net8.0;net10.0 | Skip .NET 9 (STS, superseded) |
| .NET 11 (STS) ships | net8.0;net10.0;net11.0 | 11 > 10, include it |
| .NET 12 (LTS) ships | net10.0;net12.0 | .NET 8 drops; 11 superseded |
Libraries with no framework dependency (no domain prefix) should also target netstandard2.0/netstandard2.1 when APIs and dependencies allow. Framework-dependent libraries skip .NET Standard.
Procedure
- Ask the user for the library's purpose.
- Propose name options using the naming table above.
- Determine the correct multi-targeting based on current LTS/STS and framework dependencies.
- Create the project under
src/{LibraryName}/. - Do not specify
VersiononPackageReference— add versions inDirectory.Packages.props. - Create a matching test project under
tests/{LibraryName}.Tests/. - Add both projects to
Solution.slnx. - Verify the build compiles cleanly.
When not to use it
- →Non-.NET projects
Limitations
- →Requires manual verification of build
- →Kritikos-specific naming
How it compares
It enforces a specific, standardized structure for reusable .NET libraries, ensuring consistency across the Kritikos ecosystem.
Compared to similar skills
new-library side by side with the closest alternatives in the catalog.
| Skill | Installs | Updated | Safety | Difficulty |
|---|---|---|---|---|
| new-library (this skill) | 0 | 3mo | No flags | Intermediate |
| csharp-developer | 43 | 2mo | No flags | Advanced |
| csharp-pro | 9 | 4mo | No flags | Intermediate |
| dotnet-backend-patterns | 7 | 5mo | No flags | Advanced |
Try saying
Example prompts that trigger this skill in your AI assistant.
You might also like
csharp-developer
zenobi-us
Expert C# developer specializing in modern .NET development, ASP.NET Core, and cloud-native applications. Masters C# 12 features, Blazor, and cross-platform development with emphasis on performance and clean architecture.
csharp-pro
sickn33
Write modern C# code with advanced features like records, pattern matching, and async/await. Optimizes .NET applications, implements enterprise patterns, and ensures comprehensive testing. Use PROACTIVELY for C# refactoring, performance optimization, or complex .NET solutions.
dotnet-backend-patterns
wshobson
Master C#/.NET backend development patterns for building robust APIs, MCP servers, and enterprise applications. Covers async/await, dependency injection, Entity Framework Core, Dapper, configuration, caching, and testing with xUnit. Use when developing .NET backends, reviewing C# code, or designing API architectures.
azure-servicebus-dotnet
microsoft
Azure Service Bus SDK for .NET. Enterprise messaging with queues, topics, subscriptions, and sessions. Use for reliable message delivery, pub/sub patterns, dead letter handling, and background processing. Triggers: "Service Bus", "ServiceBusClient", "ServiceBusSender", "ServiceBusReceiver", "ServiceBusProcessor", "message queue", "pub/sub .NET", "dead letter queue".
backend-testing
exceptionless
Backend testing with xUnit, Foundatio.Xunit, integration tests with AppWebHostFactory, FluentClient, ProxyTimeProvider for time manipulation, and test data builders. Keywords: xUnit, Fact, Theory, integration tests, AppWebHostFactory, FluentClient, ProxyTimeProvider, TimeProvider, Foundatio.Xunit, TestWithLoggingBase, test data builders
azure-identity-dotnet
microsoft
Azure Identity SDK for .NET. Authentication library for Azure SDK clients using Microsoft Entra ID. Use for DefaultAzureCredential, managed identity, service principals, and developer credentials. Triggers: "Azure Identity", "DefaultAzureCredential", "ManagedIdentityCredential", "ClientSecretCredential", "authentication .NET", "Azure auth", "credential chain".