SolutionSetupTool 1.0.1
dotnet tool install --global SolutionSetupTool --version 1.0.1
dotnet new tool-manifest
dotnet tool install --local SolutionSetupTool --version 1.0.1
#tool dotnet:?package=SolutionSetupTool&version=1.0.1
nuke :add-package SolutionSetupTool --version 1.0.1
SolutionSetupTool
solution-setup is a dotnet global tool that scaffolds new .NET solutions with strong foundations and an optional Clean Architecture layout. It creates solution files, central package management, and starter projects so you can begin coding immediately with consistent conventions.
Installation
dotnet pack src/SolutionSetup.Cli/SolutionSetup.Cli.csproj -c Release -o artifacts
dotnet tool install --global SolutionSetupTool --add-source ./artifacts
solution-setup --help
Prerequisites:
- .NET SDK 10.0.x to install and run the tool itself.
- Generated solutions can target
net9.0ornet10.0; you need the matching SDKs when building the generated solutions.
Usage
Minimal foundation layout:
solution-setup --solutionName BookingService
Clean Architecture layout with API presentation:
solution-setup \
--solutionName BookingService \
--layout clean \
--presentation api \
--framework net10.0 \
--testFramework xunit
Switch frameworks to exercise different profiles:
solution-setup --solutionName BookingService --layout clean --framework net9.0 # default profile
solution-setup --solutionName BookingService --layout clean --framework net10.0 # net10.0 profile (e.g., Serilog 10.x)
Key options:
--solutionName(required) solution name and project prefix.--pathtarget directory (defaults to current).--frameworktarget framework (defaultnet9.0;net9.0andnet10.0are supported today).--layoutfoundationorclean(defaultfoundation).--testFrameworkxunit(default). Other frameworks can be added by extending package sets.--presentationapiormvcfor the clean layout (defaultapi).--skipGlobalJsonomitglobal.json.--dryRunshow actions without writing files.
Support matrix:
- Layouts: foundation, clean
- Frameworks: net9.0, net10.0
- Presentation (clean): api (minimal API), mvc
- Test framework: xunit (extensible)
Generated Structure
- Root solution
{SolutionName}.slnwith solution items.editorconfig,Directory.Build.props,Directory.Packages.props, optionalglobal.json. - Layouts:
foundation: unopinionated; only solution items are created (no projects or folders).clean: Domain, Application, Infrastructure, Presentation (ApiorWeb), and Domain unit tests. Includes a minimal end-to-end example, with projects placed undersrcandtests. Forapi, WeatherForecast samples are removed andProgram.csis replaced with a minimal health endpoint.
- Global JSON: the SDK version is resolved from installed SDKs; if resolution fails, it falls back to
8.0.400to stay compatible with widely available LTS bits. - Packages and solution items: for each supported framework we keep a profile of package versions (including Serilog and testing packages) and solution items; central package management is generated from that profile so
net9.0andnet10.0can diverge safely. .editorconfig: concise, cross-platform defaults (LF line endings, 4-space indentation, file-scoped namespaces, braces required) tailored for C#.
Why this tool?
- Consistent starter structure (foundation or clean) with central package management.
- Minimal API scaffolding without template noise.
- Extensible profiles and layouts (see docs/architecture.md, docs/extending.md).
Packaging / Publishing
Create a release package with deterministic build settings:
dotnet pack src/SolutionSetup.Cli/SolutionSetup.Cli.csproj -c Release /p:ContinuousIntegrationBuild=true
Install/test locally as a global tool (no NuGet push needed):
dotnet tool install --global SolutionSetupTool --add-source ./src/SolutionSetup.Cli/bin/Release
solution-setup --help
Publish to NuGet:
dotnet nuget push src/SolutionSetup.Cli/bin/Release/SolutionSetupTool.*.nupkg --source https://api.nuget.org/v3/index.json
See docs/architecture.md, docs/layouts.md, docs/usage.md, docs/releasing.md, docs/roadmap.md, and docs/extending.md for deeper details.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
This package has no dependencies.