dotnet-local-tools

Manage per-repository .NET CLI tool versions via .config/dotnet-tools.json.

Updated Jan 29, 2024
One-click install
npx skills add https://github.com/riandeoliveira/aspnet-template --skill dotnet-local-tools-riandeoliveira
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dotnet-local-tools
Source: https://github.com/riandeoliveira/aspnet-template/tree/main/.claude/skills/local-tools
Command: npx skills add https://github.com/riandeoliveira/aspnet-template --skill dotnet-local-tools-riandeoliveira

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

It solves inconsistent development and CI/CD tooling by ensuring every developer and build pipeline uses the same .NET local tool versions defined for the repository.

Core Features & Use Cases

  • Repository-scoped tool management: Install and restore tools per project/repo using .config/dotnet-tools.json to avoid global version conflicts.
  • Deterministic installs for CI/CD: Use dotnet tool restore so pipelines install exactly the pinned versions before running build, test, documentation, or reporting steps.
  • Practical scenarios: Manage common repo tools like docfx for docs, dotnet-ef for migrations, reportgenerator for coverage reporting, and incrementalist for change-scoped builds.

Quick Start

From your repository root, run dotnet tool restore to install all locally pinned tools defined in .config/dotnet-tools.json.

Frequently Asked Questions about dotnet-local-tools

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I pin .NET CLI tool versions per repository for consistent CI/CD builds?

Run `dotnet tool restore` in your pipeline before build, test, or documentation steps to install the exact pinned versions defined in your repository's `.config/dotnet-tools.json` manifest file.

What are .NET local tools and when do I need a tool manifest?

.NET local tools are CLI utilities scoped to a specific repository rather than installed globally. You need a `.config/dotnet-tools.json` tool manifest when your project relies on tools like dotnet-ef or docfx to ensure reproducible builds across environments.

Does dotnet tool restore work with docfx, dotnet-ef, and reportgenerator in build pipelines?

Yes, `dotnet tool restore` installs pinned versions of repo-local tools including docfx, dotnet-ef, reportgenerator, and incrementalist, ensuring consistent execution for documentation, migrations, and coverage reporting workflows in CI/CD.

What's the best way to manage dotnet-ef migrations and docfx versions across a development team?

The best way is using a repository-level `.config/dotnet-tools.json` manifest to pin tool versions. This prevents global version conflicts and ensures every team member and pipeline restores identical dotnet-ef and docfx versions.

Why do my .NET local tools have different versions in local development versus CI/CD?

Version mismatches occur when tools are installed globally instead of per-repository. Using a `.config/dotnet-tools.json` manifest with `dotnet tool restore` enforces pinned versions and reproducible roll-forward behavior across both environments.