...
Run the following command to show a listing of the current templates:
List Templates Command
Code Block | ||
---|---|---|
| ||
dotnet new -l |
...
As an example the Poller template will be installed. To install we need the following command, (which is dependent on where you put the repository):
Install Template Command
Code Block | ||
---|---|---|
| ||
dotnet new -i [RootTemplateFolder] |
...
So in my case, to install the template, the following command needs to be executed:
Install Template Command
Code Block | ||
---|---|---|
| ||
dotnet new -i E:\Code\Templates\Orp.Core.Poller.Template |
...
Step 3: From template to an application.
To create an application from the template the following command needs to be executed:
Create Application Command
Code Block | ||
---|---|---|
| ||
dotnet new [template-short-name] -o [directory] -n [name] |
...
Example: we want to create a Product Poller for Aspos. (SL/Valk Solution ERP), then the command will become:
Create Application Command
Code Block | ||
---|---|---|
| ||
dotnet new wolfpack-poller-template -o E:\Code\Orp.Core.Products.Poller.Aspos -n Orp.Core.Products.Poller.Aspos |
...
Uninstalling a template:
In case you don't want the template after it has been installed, use the following command:
Uninstall Template Command:
Code Block | ||
---|---|---|
| ||
dotnet new -u [RootTemplateFolder] |
With reference to the example this would become:
Uninstall Template Command
Code Block | ||
---|---|---|
| ||
dotnet new -u E:\Code\Templates\Orp.Core.Poller.Template |
...