Reputation: 3591
I've created a bare-bone git-repository with a Github Action which builds and publishes a nuget package containing 2 .NET templates. These templates can be installed using
dotnet new --install MintPlayer.AspNetCore.IdentityServer.Templates
Then you can create a new project using
dotnet new id-provider
But these templates aren't available from Visual Studio 2022, even though I've added the .template.config/ide.host.json
file:
{
"$schema": "http://json.schemastore.org/vs-2017.3.host",
"order": 0,
"icon": "music_note_64.png",
"symbolInfo": [
]
}
What do I need to do to get them into Visual Studio 2022 too? Do I need a VSIX package, like in this example? Is it necessary to upload a VSIX to the Visual Studio Marketplace?
Here's a similar question, but it's from when this was an experimental feature. Now this option doesn't seem to exist anymore.
Here too they mention the experimental feature which I can't find anymore...
Upvotes: -1
Views: 840
Reputation: 3591
Ok so apparently I was missing the following in the template.json
file
"tags": {
"language": "C#",
"type": "project"
}
And it seems that you also have to take the following into account:
Name | Description |
---|---|
groupIdentity | The ID of the group this template belongs to. When combined with the tagssection, this allows multiple templates to be displayed as one, with the the decision for which one to use being presented as a choice in each one of the pivot categories (keys) |
So if you want them in Visual Studio as 2 separate templates, you need different values for groupIdentity
Upvotes: 0