This repository contains a collection of templates for the dotnet new command based on my own preferences.
This might not be overly useful for you, but it was a fun experiment and this repo at least shows of some of the features available when creating your own templates.
Just run the following command to install the templates.
dotnet new install Karls.TemplatesIf you have them installed and need to update them you can run the above command again.
Or simply this to update all template packages (which is often a good idea).
dotnet new updateThis template creates a solution with a single Core project (+tests) and some default settings based on my own preferences.
dotnet new karls-solution -n Company.CoolProjectSince version 1.4.0 a flag can be passed to also generate a frontend
project based on Vite and other tools. To have this just pass
--addFrontendProject when creating the project.
dotnet new karls-solution -n CoolProject --addFrontendProjectThe project per default includes a set of Github Actions workflows.
If another CI tool is to be used these can be skipped by setting
includeGithubActions to false. This will still add a depenadbot
configuration though since I host all my projects on Github.
dotnet new karls-solution -n CoolProject --includeGithubActions=falseTo see available options, run this.
dotnet new karls-solution --helpIncludes an adapted version of https://github.com/hrvey/combine-prs-workflow/