From 33eead9332598f4fa8434efad31c03b0619fbbd9 Mon Sep 17 00:00:00 2001 From: Vlada Shubina Date: Wed, 7 Dec 2022 15:54:14 +0100 Subject: [PATCH 1/9] templates for template authoring: first draft --- Microsoft.TemplateEngine.sln | 17 +++++ ....TemplateEngine.Authoring.Templates.csproj | 35 ++++++++++ .../README.md | 10 +++ .../content/README.md | 7 ++ .../.template.config/dotnetcli.host.json | 21 ++++++ .../localize/templatestrings.cs.json | 13 ++++ .../localize/templatestrings.de.json | 13 ++++ .../localize/templatestrings.en.json | 13 ++++ .../localize/templatestrings.es.json | 13 ++++ .../localize/templatestrings.fr.json | 13 ++++ .../localize/templatestrings.it.json | 13 ++++ .../localize/templatestrings.ja.json | 13 ++++ .../localize/templatestrings.ko.json | 13 ++++ .../localize/templatestrings.pl.json | 13 ++++ .../localize/templatestrings.pt-BR.json | 13 ++++ .../localize/templatestrings.ru.json | 13 ++++ .../localize/templatestrings.tr.json | 13 ++++ .../localize/templatestrings.zh-Hans.json | 13 ++++ .../localize/templatestrings.zh-Hant.json | 13 ++++ .../.template.config/template.json | 67 +++++++++++++++++++ .../content/TemplateJson/template.json | 49 ++++++++++++++ .../.template.config/dotnetcli.host.json | 24 +++++++ .../localize/templatestrings.cs.json | 5 ++ .../localize/templatestrings.de.json | 5 ++ .../localize/templatestrings.en.json | 5 ++ .../localize/templatestrings.es.json | 5 ++ .../localize/templatestrings.fr.json | 5 ++ .../localize/templatestrings.it.json | 5 ++ .../localize/templatestrings.ja.json | 5 ++ .../localize/templatestrings.ko.json | 5 ++ .../localize/templatestrings.pl.json | 5 ++ .../localize/templatestrings.pt-BR.json | 5 ++ .../localize/templatestrings.ru.json | 5 ++ .../localize/templatestrings.tr.json | 5 ++ .../localize/templatestrings.zh-Hans.json | 5 ++ .../localize/templatestrings.zh-Hant.json | 5 ++ .../.template.config/template.json | 31 +++++++++ .../New.Template.Package.csproj | 32 +++++++++ .../place_the_template_content_here | 0 template_feed/README.md | 2 +- 40 files changed, 546 insertions(+), 1 deletion(-) create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/Microsoft.TemplateEngine.Authoring.Templates.csproj create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/README.md create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/README.md create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/dotnetcli.host.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.cs.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.de.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.en.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.es.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.fr.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.it.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ja.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ko.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pl.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pt-BR.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ru.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.tr.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hans.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hant.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/template.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/dotnetcli.host.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.cs.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.de.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.en.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.es.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.fr.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.it.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ja.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ko.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pl.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pt-BR.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ru.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.tr.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hans.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hant.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/content/SampleTemplate/place_the_template_content_here diff --git a/Microsoft.TemplateEngine.sln b/Microsoft.TemplateEngine.sln index 392461e372a..4db383347b5 100644 --- a/Microsoft.TemplateEngine.sln +++ b/Microsoft.TemplateEngine.sln @@ -106,6 +106,10 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "template-samples", "templat EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.TemplateEngine.Samples", "dotnet-template-samples\Microsoft.TemplateEngine.Samples.csproj", "{DFB06A25-719F-4C8B-B84D-55D2D601BEF6}" EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "template-feed", "template-feed", "{FF433F83-22C2-46E0-99B3-4FFCA5190A94}" +EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.TemplateEngine.Authoring.Templates", "template_feed\Microsoft.TemplateEngine.Authoring.Templates\Microsoft.TemplateEngine.Authoring.Templates.csproj", "{1F74F8F5-99E4-47AE-8608-6D470325E81C}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -500,6 +504,18 @@ Global {DFB06A25-719F-4C8B-B84D-55D2D601BEF6}.Release|x64.Build.0 = Release|Any CPU {DFB06A25-719F-4C8B-B84D-55D2D601BEF6}.Release|x86.ActiveCfg = Release|Any CPU {DFB06A25-719F-4C8B-B84D-55D2D601BEF6}.Release|x86.Build.0 = Release|Any CPU + {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Debug|Any CPU.Build.0 = Debug|Any CPU + {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Debug|x64.ActiveCfg = Debug|Any CPU + {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Debug|x64.Build.0 = Debug|Any CPU + {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Debug|x86.ActiveCfg = Debug|Any CPU + {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Debug|x86.Build.0 = Debug|Any CPU + {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Release|Any CPU.ActiveCfg = Release|Any CPU + {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Release|Any CPU.Build.0 = Release|Any CPU + {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Release|x64.ActiveCfg = Release|Any CPU + {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Release|x64.Build.0 = Release|Any CPU + {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Release|x86.ActiveCfg = Release|Any CPU + {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Release|x86.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -540,6 +556,7 @@ Global {EE8CD472-D8C4-4CD0-BC84-6C305F5971AE} = {43053BC4-32B4-4404-B62D-410F367CE0CE} {449B9DDA-F18C-411E-9A74-3930652BB78A} = {B794BF86-4185-4DCE-AC86-C27D5D966B9B} {DFB06A25-719F-4C8B-B84D-55D2D601BEF6} = {3A2D12C2-0455-4471-9EBB-91749BA3A60F} + {1F74F8F5-99E4-47AE-8608-6D470325E81C} = {FF433F83-22C2-46E0-99B3-4FFCA5190A94} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {6EA1A508-6033-4538-BF98-7F71B4E297AD} diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/Microsoft.TemplateEngine.Authoring.Templates.csproj b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/Microsoft.TemplateEngine.Authoring.Templates.csproj new file mode 100644 index 00000000000..d79baa62a79 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/Microsoft.TemplateEngine.Authoring.Templates.csproj @@ -0,0 +1,35 @@ + + + $(NETCoreTargetFramework) + False + False + False + $(ArtifactsTmpDir) + False + true + true + true + true + 2008;NU5105 + true + Microsoft.TemplateEngine.Authoring.Templates + Microsoft + The templates for useful items and projects for template authoring. + en-US + https://github.com/dotnet/templating + Template + True + + + + + content + + + + + + + + + diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/README.md b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/README.md new file mode 100644 index 00000000000..c67306cee7a --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/README.md @@ -0,0 +1,10 @@ +## The templates for template authoring + +The package contains the templates useful for the template authoring: +| Template name | Short name | Description| +|---|---|---| +|`template.json` configuration file|`template.json`|A template for template.json configuration file for .NET template.| +|Template Package|`template-package`|A project for creating template package containing .NET templates.| + +The package is available for download from nuget.org. +Please feel to contribute or provide the feedback in discussions or via opening the issue in dotnet/templating repo. diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/README.md b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/README.md new file mode 100644 index 00000000000..1c373af9dac --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/README.md @@ -0,0 +1,7 @@ +## The templates for template authoring + +The project contains the templates useful for the template authoring: +| Template name | Short name | Description | +|---|---|---| +|`template.json` configuration file|`template.json`|A template for template.json configuration file for .NET template.| +|Template Package|`template-package`|A project for template package containing .NET templates.| diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/dotnetcli.host.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/dotnetcli.host.json new file mode 100644 index 00000000000..adb957225fa --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/dotnetcli.host.json @@ -0,0 +1,21 @@ +{ + "$schema": "http://json.schemastore.org/dotnetcli.host", + "symbolInfo": { + "CreateTemplateConfigFolder": { + "longName": "create-template-config-folder", + "shortName": "" + }, + "TemplateName": { + "longName": "template-name", + "shortName": "tn" + }, + "TemplateShortName": { + "longName": "short-name", + "shortName": "sn" + }, + "TemplateIdentity": { + "longName": "template-identity", + "shortName": "ti" + } + } +} diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.cs.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.cs.json new file mode 100644 index 00000000000..25c1290652e --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.cs.json @@ -0,0 +1,13 @@ +{ + "author": "Microsoft", + "name": "template.json", + "description": "A template for template.json configuration file for .NET template.", + "symbols/CreateTemplateConfigFolder/description": "True when template.json should be created in .template.config folder.", + "symbols/CreateTemplateConfigFolder/displayName": "Create .template.config folder", + "symbols/TemplateName/description": "The template name.", + "symbols/TemplateName/displayName": "Template name", + "symbols/TemplateShortName/description": "The template short name.", + "symbols/TemplateShortName/displayName": "Template short name", + "symbols/TemplateIdentity/description": "The template identity (should be unique).", + "symbols/TemplateIdentity/displayName": "Template identity" +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.de.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.de.json new file mode 100644 index 00000000000..25c1290652e --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.de.json @@ -0,0 +1,13 @@ +{ + "author": "Microsoft", + "name": "template.json", + "description": "A template for template.json configuration file for .NET template.", + "symbols/CreateTemplateConfigFolder/description": "True when template.json should be created in .template.config folder.", + "symbols/CreateTemplateConfigFolder/displayName": "Create .template.config folder", + "symbols/TemplateName/description": "The template name.", + "symbols/TemplateName/displayName": "Template name", + "symbols/TemplateShortName/description": "The template short name.", + "symbols/TemplateShortName/displayName": "Template short name", + "symbols/TemplateIdentity/description": "The template identity (should be unique).", + "symbols/TemplateIdentity/displayName": "Template identity" +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.en.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.en.json new file mode 100644 index 00000000000..f8f9ad21eb6 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.en.json @@ -0,0 +1,13 @@ +{ + "author": "Microsoft", + "name": "template.json configuration file", + "description": "A template for template.json configuration file for .NET template. See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description", + "symbols/CreateTemplateConfigFolder/description": "True when template.json should be created in .template.config folder.", + "symbols/CreateTemplateConfigFolder/displayName": "Create .template.config folder", + "symbols/TemplateName/description": "The template name.", + "symbols/TemplateName/displayName": "Template name", + "symbols/TemplateShortName/description": "The template short name.", + "symbols/TemplateShortName/displayName": "Template short name", + "symbols/TemplateIdentity/description": "The template identity (should be unique).", + "symbols/TemplateIdentity/displayName": "Template identity" +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.es.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.es.json new file mode 100644 index 00000000000..25c1290652e --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.es.json @@ -0,0 +1,13 @@ +{ + "author": "Microsoft", + "name": "template.json", + "description": "A template for template.json configuration file for .NET template.", + "symbols/CreateTemplateConfigFolder/description": "True when template.json should be created in .template.config folder.", + "symbols/CreateTemplateConfigFolder/displayName": "Create .template.config folder", + "symbols/TemplateName/description": "The template name.", + "symbols/TemplateName/displayName": "Template name", + "symbols/TemplateShortName/description": "The template short name.", + "symbols/TemplateShortName/displayName": "Template short name", + "symbols/TemplateIdentity/description": "The template identity (should be unique).", + "symbols/TemplateIdentity/displayName": "Template identity" +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.fr.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.fr.json new file mode 100644 index 00000000000..25c1290652e --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.fr.json @@ -0,0 +1,13 @@ +{ + "author": "Microsoft", + "name": "template.json", + "description": "A template for template.json configuration file for .NET template.", + "symbols/CreateTemplateConfigFolder/description": "True when template.json should be created in .template.config folder.", + "symbols/CreateTemplateConfigFolder/displayName": "Create .template.config folder", + "symbols/TemplateName/description": "The template name.", + "symbols/TemplateName/displayName": "Template name", + "symbols/TemplateShortName/description": "The template short name.", + "symbols/TemplateShortName/displayName": "Template short name", + "symbols/TemplateIdentity/description": "The template identity (should be unique).", + "symbols/TemplateIdentity/displayName": "Template identity" +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.it.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.it.json new file mode 100644 index 00000000000..25c1290652e --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.it.json @@ -0,0 +1,13 @@ +{ + "author": "Microsoft", + "name": "template.json", + "description": "A template for template.json configuration file for .NET template.", + "symbols/CreateTemplateConfigFolder/description": "True when template.json should be created in .template.config folder.", + "symbols/CreateTemplateConfigFolder/displayName": "Create .template.config folder", + "symbols/TemplateName/description": "The template name.", + "symbols/TemplateName/displayName": "Template name", + "symbols/TemplateShortName/description": "The template short name.", + "symbols/TemplateShortName/displayName": "Template short name", + "symbols/TemplateIdentity/description": "The template identity (should be unique).", + "symbols/TemplateIdentity/displayName": "Template identity" +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ja.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ja.json new file mode 100644 index 00000000000..25c1290652e --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ja.json @@ -0,0 +1,13 @@ +{ + "author": "Microsoft", + "name": "template.json", + "description": "A template for template.json configuration file for .NET template.", + "symbols/CreateTemplateConfigFolder/description": "True when template.json should be created in .template.config folder.", + "symbols/CreateTemplateConfigFolder/displayName": "Create .template.config folder", + "symbols/TemplateName/description": "The template name.", + "symbols/TemplateName/displayName": "Template name", + "symbols/TemplateShortName/description": "The template short name.", + "symbols/TemplateShortName/displayName": "Template short name", + "symbols/TemplateIdentity/description": "The template identity (should be unique).", + "symbols/TemplateIdentity/displayName": "Template identity" +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ko.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ko.json new file mode 100644 index 00000000000..25c1290652e --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ko.json @@ -0,0 +1,13 @@ +{ + "author": "Microsoft", + "name": "template.json", + "description": "A template for template.json configuration file for .NET template.", + "symbols/CreateTemplateConfigFolder/description": "True when template.json should be created in .template.config folder.", + "symbols/CreateTemplateConfigFolder/displayName": "Create .template.config folder", + "symbols/TemplateName/description": "The template name.", + "symbols/TemplateName/displayName": "Template name", + "symbols/TemplateShortName/description": "The template short name.", + "symbols/TemplateShortName/displayName": "Template short name", + "symbols/TemplateIdentity/description": "The template identity (should be unique).", + "symbols/TemplateIdentity/displayName": "Template identity" +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pl.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pl.json new file mode 100644 index 00000000000..25c1290652e --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pl.json @@ -0,0 +1,13 @@ +{ + "author": "Microsoft", + "name": "template.json", + "description": "A template for template.json configuration file for .NET template.", + "symbols/CreateTemplateConfigFolder/description": "True when template.json should be created in .template.config folder.", + "symbols/CreateTemplateConfigFolder/displayName": "Create .template.config folder", + "symbols/TemplateName/description": "The template name.", + "symbols/TemplateName/displayName": "Template name", + "symbols/TemplateShortName/description": "The template short name.", + "symbols/TemplateShortName/displayName": "Template short name", + "symbols/TemplateIdentity/description": "The template identity (should be unique).", + "symbols/TemplateIdentity/displayName": "Template identity" +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pt-BR.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pt-BR.json new file mode 100644 index 00000000000..25c1290652e --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pt-BR.json @@ -0,0 +1,13 @@ +{ + "author": "Microsoft", + "name": "template.json", + "description": "A template for template.json configuration file for .NET template.", + "symbols/CreateTemplateConfigFolder/description": "True when template.json should be created in .template.config folder.", + "symbols/CreateTemplateConfigFolder/displayName": "Create .template.config folder", + "symbols/TemplateName/description": "The template name.", + "symbols/TemplateName/displayName": "Template name", + "symbols/TemplateShortName/description": "The template short name.", + "symbols/TemplateShortName/displayName": "Template short name", + "symbols/TemplateIdentity/description": "The template identity (should be unique).", + "symbols/TemplateIdentity/displayName": "Template identity" +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ru.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ru.json new file mode 100644 index 00000000000..25c1290652e --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ru.json @@ -0,0 +1,13 @@ +{ + "author": "Microsoft", + "name": "template.json", + "description": "A template for template.json configuration file for .NET template.", + "symbols/CreateTemplateConfigFolder/description": "True when template.json should be created in .template.config folder.", + "symbols/CreateTemplateConfigFolder/displayName": "Create .template.config folder", + "symbols/TemplateName/description": "The template name.", + "symbols/TemplateName/displayName": "Template name", + "symbols/TemplateShortName/description": "The template short name.", + "symbols/TemplateShortName/displayName": "Template short name", + "symbols/TemplateIdentity/description": "The template identity (should be unique).", + "symbols/TemplateIdentity/displayName": "Template identity" +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.tr.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.tr.json new file mode 100644 index 00000000000..25c1290652e --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.tr.json @@ -0,0 +1,13 @@ +{ + "author": "Microsoft", + "name": "template.json", + "description": "A template for template.json configuration file for .NET template.", + "symbols/CreateTemplateConfigFolder/description": "True when template.json should be created in .template.config folder.", + "symbols/CreateTemplateConfigFolder/displayName": "Create .template.config folder", + "symbols/TemplateName/description": "The template name.", + "symbols/TemplateName/displayName": "Template name", + "symbols/TemplateShortName/description": "The template short name.", + "symbols/TemplateShortName/displayName": "Template short name", + "symbols/TemplateIdentity/description": "The template identity (should be unique).", + "symbols/TemplateIdentity/displayName": "Template identity" +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hans.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hans.json new file mode 100644 index 00000000000..25c1290652e --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hans.json @@ -0,0 +1,13 @@ +{ + "author": "Microsoft", + "name": "template.json", + "description": "A template for template.json configuration file for .NET template.", + "symbols/CreateTemplateConfigFolder/description": "True when template.json should be created in .template.config folder.", + "symbols/CreateTemplateConfigFolder/displayName": "Create .template.config folder", + "symbols/TemplateName/description": "The template name.", + "symbols/TemplateName/displayName": "Template name", + "symbols/TemplateShortName/description": "The template short name.", + "symbols/TemplateShortName/displayName": "Template short name", + "symbols/TemplateIdentity/description": "The template identity (should be unique).", + "symbols/TemplateIdentity/displayName": "Template identity" +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hant.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hant.json new file mode 100644 index 00000000000..25c1290652e --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hant.json @@ -0,0 +1,13 @@ +{ + "author": "Microsoft", + "name": "template.json", + "description": "A template for template.json configuration file for .NET template.", + "symbols/CreateTemplateConfigFolder/description": "True when template.json should be created in .template.config folder.", + "symbols/CreateTemplateConfigFolder/displayName": "Create .template.config folder", + "symbols/TemplateName/description": "The template name.", + "symbols/TemplateName/displayName": "Template name", + "symbols/TemplateShortName/description": "The template short name.", + "symbols/TemplateShortName/displayName": "Template short name", + "symbols/TemplateIdentity/description": "The template identity (should be unique).", + "symbols/TemplateIdentity/displayName": "Template identity" +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/template.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/template.json new file mode 100644 index 00000000000..98a3b5b183d --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/template.json @@ -0,0 +1,67 @@ +{ + "$schema": "http://json.schemastore.org/template", + "author": "Microsoft", + "classifications": [ + "Template Authoring" + ], + "name": "template.json configuration file", + "generatorVersions": "[1.0.0.0-*)", + "description": "A template for template.json configuration file for .NET template. See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description", + "groupIdentity": "Microsoft.TemplateEngine.Authoring.TemplateJson", + "precedence": "0", + "identity": "Microsoft.TemplateEngine.Authoring.TemplateJson.1.0", + "shortName": "template.json", + "tags": { + "language": "JSON", + "type": "item" + }, + "symbols": { + "CreateTemplateConfigFolder": { + "type": "parameter", + "datatype": "bool", + "description": "True when template.json should be created in .template.config folder.", + "defaultValue": "true", + "displayName": "Create .template.config folder" + }, + "TemplateName": { + "type": "parameter", + "datatype": "string", + "description": "The template name.", + "defaultValue": "New Template", + "replaces": "New Template", + "displayName": "Template name" + }, + "TemplateShortName": { + "type": "parameter", + "datatype": "string", + "description": "The template short name.", + "defaultValue": "new-template", + "replaces": "new-template", + "displayName": "Template short name" + }, + "TemplateIdentity": { + "type": "parameter", + "datatype": "string", + "description": "The template identity (should be unique).", + "defaultValue": "New.Template.Identity", + "replaces": "New.Template.Identity", + "displayName": "Template identity" + } + }, + "sources": [ + { + "condition": "CreateTemplateConfigFolder == true", + "target": ".template.config/" + } + ], + "primaryOutputs": [ + { + "condition": "CreateTemplateConfigFolder == true", + "path": ".template.config/template.json" + }, + { + "condition": "CreateTemplateConfigFolder != true", + "path": "template.json" + } + ] +} diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json new file mode 100644 index 00000000000..5a47097aab8 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json @@ -0,0 +1,49 @@ +{ + "$schema": "http://json.schemastore.org/template", + "_comment": "See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description. Complete TODOs below and remove the _comment properties.It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", + "author": "TODO: fill author name here.", + "classifications": [ + "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." + ], + "name": "New Template", + "description": "TODO: fill the template description here.", + "precedence": "0", + "identity": "New.Template.Identity", + "shortName": "new-template", + "tags": { + "_comment": "TODO: fill the language and type below. Common types are: project, item, solution.", + "language": "C#", + "type": "project" + }, + "_comment_sourceName": "TODO: Source name should follow these rules: https://github.com/dotnet/templating/wiki/Naming-and-default-value-forms. Source name may be removed if replacement for name is not required.", + "sourceName": "New.Template.1", + "preferNameDirectory": true, + "symbols": { + "_comment": "TODO: The symbols section defines variables and their values. For more details, see https://github.com/dotnet/templating/wiki/Reference-for-template.json#symbols.", + "ExampleParameter":{ + "type": "parameter", + "datatype": "string", + "defaultValue": "example", + "replaces": "valueToReplace", + "isEnabled": false + } + }, + "sources": [ + { + "_comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property." + } + ], + "constraints": { + "_comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property." + }, + "primaryOutputs": [ + { + "_comment": "TODO: Primary outputs define the list of template files for further processing, usually post actions. If primary outputs are not required, remove the property." + } + ], + "postActions": [ + { + "_comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property." + } + ] +} diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/dotnetcli.host.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/dotnetcli.host.json new file mode 100644 index 00000000000..17930d81b4f --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/dotnetcli.host.json @@ -0,0 +1,24 @@ +{ + "$schema": "http://json.schemastore.org/dotnetcli.host", + "symbolInfo": { + "TargetFrameworkOverride": { + "isHidden": "true", + "longName": "target-framework-override", + "shortName": "" + }, + "Framework": { + "longName": "framework" + }, + "skipRestore": { + "longName": "no-restore", + "shortName": "" + }, + "langVersion": { + "longName": "langVersion", + "shortName": "" + } + }, + "usageExamples": [ + "--framework net7.0" + ] +} diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.cs.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.cs.json new file mode 100644 index 00000000000..9b1b2aebb84 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.cs.json @@ -0,0 +1,5 @@ +{ + "author": "Microsoft", + "name": "Template Package", + "description": "A project for creating template package containing .NET templates." +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.de.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.de.json new file mode 100644 index 00000000000..9b1b2aebb84 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.de.json @@ -0,0 +1,5 @@ +{ + "author": "Microsoft", + "name": "Template Package", + "description": "A project for creating template package containing .NET templates." +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.en.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.en.json new file mode 100644 index 00000000000..500d4bac663 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.en.json @@ -0,0 +1,5 @@ +{ + "author": "Microsoft", + "name": "Template Package", + "description": "A project for a template package containing .NET templates." +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.es.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.es.json new file mode 100644 index 00000000000..9b1b2aebb84 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.es.json @@ -0,0 +1,5 @@ +{ + "author": "Microsoft", + "name": "Template Package", + "description": "A project for creating template package containing .NET templates." +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.fr.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.fr.json new file mode 100644 index 00000000000..9b1b2aebb84 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.fr.json @@ -0,0 +1,5 @@ +{ + "author": "Microsoft", + "name": "Template Package", + "description": "A project for creating template package containing .NET templates." +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.it.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.it.json new file mode 100644 index 00000000000..9b1b2aebb84 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.it.json @@ -0,0 +1,5 @@ +{ + "author": "Microsoft", + "name": "Template Package", + "description": "A project for creating template package containing .NET templates." +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ja.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ja.json new file mode 100644 index 00000000000..9b1b2aebb84 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ja.json @@ -0,0 +1,5 @@ +{ + "author": "Microsoft", + "name": "Template Package", + "description": "A project for creating template package containing .NET templates." +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ko.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ko.json new file mode 100644 index 00000000000..9b1b2aebb84 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ko.json @@ -0,0 +1,5 @@ +{ + "author": "Microsoft", + "name": "Template Package", + "description": "A project for creating template package containing .NET templates." +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pl.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pl.json new file mode 100644 index 00000000000..9b1b2aebb84 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pl.json @@ -0,0 +1,5 @@ +{ + "author": "Microsoft", + "name": "Template Package", + "description": "A project for creating template package containing .NET templates." +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pt-BR.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pt-BR.json new file mode 100644 index 00000000000..9b1b2aebb84 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pt-BR.json @@ -0,0 +1,5 @@ +{ + "author": "Microsoft", + "name": "Template Package", + "description": "A project for creating template package containing .NET templates." +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ru.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ru.json new file mode 100644 index 00000000000..9b1b2aebb84 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ru.json @@ -0,0 +1,5 @@ +{ + "author": "Microsoft", + "name": "Template Package", + "description": "A project for creating template package containing .NET templates." +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.tr.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.tr.json new file mode 100644 index 00000000000..9b1b2aebb84 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.tr.json @@ -0,0 +1,5 @@ +{ + "author": "Microsoft", + "name": "Template Package", + "description": "A project for creating template package containing .NET templates." +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hans.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hans.json new file mode 100644 index 00000000000..9b1b2aebb84 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hans.json @@ -0,0 +1,5 @@ +{ + "author": "Microsoft", + "name": "Template Package", + "description": "A project for creating template package containing .NET templates." +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hant.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hant.json new file mode 100644 index 00000000000..9b1b2aebb84 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hant.json @@ -0,0 +1,5 @@ +{ + "author": "Microsoft", + "name": "Template Package", + "description": "A project for creating template package containing .NET templates." +} \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json new file mode 100644 index 00000000000..f5c177a2442 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json @@ -0,0 +1,31 @@ +{ + "$schema": "http://json.schemastore.org/template", + "author": "Microsoft", + "classifications": [ + "Template Authoring" + ], + "name": "Template Package", + "generatorVersions": "[1.0.0.0-*)", + "description": "A project for a template package containing .NET templates.", + "groupIdentity": "Microsoft.TemplateEngine.Authoring.TemplatePackage", + "precedence": "0", + "identity": "Microsoft.TemplateEngine.Authoring.TemplatePackage.1.0", + "shortName": "template-package", + "tags": { + "type": "project" + }, + "sourceName": "New.Template.Package", + "symbols": { + "EnableMSBuildTasks": + { + "type": "parameter", + "datatype": "bool", + "defaultValue": "true" + } + }, + "primaryOutputs": [ + { + "path": "New.Template.Package.csproj" + } + ] +} diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj new file mode 100644 index 00000000000..9d0b22b8520 --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj @@ -0,0 +1,32 @@ + + + + Template + 1.0 + New.Template.Package + TODO: fill the package name here + Me + TODO: fill the package description here + dotnet-new;templates + net7.0 + true + false + content + $(NoWarn);NU5128 + true + + + + false + + + + + + + + + + + + \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/content/SampleTemplate/place_the_template_content_here b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/content/SampleTemplate/place_the_template_content_here new file mode 100644 index 00000000000..e69de29bb2d diff --git a/template_feed/README.md b/template_feed/README.md index 18e8a7cf1a9..0e58ff97cd0 100644 --- a/template_feed/README.md +++ b/template_feed/README.md @@ -1 +1 @@ -The source code is moved to [dotnet/sdk](https://github.com/dotnet/sdk/tree/main/template_feed). \ No newline at end of file +The source code for common item and common project templates is moved to [dotnet/sdk](https://github.com/dotnet/sdk/tree/main/template_feed). \ No newline at end of file From 4a571fd8e09b5a043584e8a19d41a9888b2abdf6 Mon Sep 17 00:00:00 2001 From: Vlada Shubina Date: Thu, 8 Dec 2022 16:21:13 +0100 Subject: [PATCH 2/9] renamed comment properties --- .../content/TemplateJson/template.json | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json index 5a47097aab8..6b7e60774d4 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json @@ -1,6 +1,6 @@ { "$schema": "http://json.schemastore.org/template", - "_comment": "See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description. Complete TODOs below and remove the _comment properties.It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", + "$comment": "See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description. Complete TODOs below and remove the _comment properties.It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", "author": "TODO: fill author name here.", "classifications": [ "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." @@ -11,15 +11,15 @@ "identity": "New.Template.Identity", "shortName": "new-template", "tags": { - "_comment": "TODO: fill the language and type below. Common types are: project, item, solution.", + "$comment": "TODO: fill the language and type below. Common types are: project, item, solution.", "language": "C#", "type": "project" }, - "_comment_sourceName": "TODO: Source name should follow these rules: https://github.com/dotnet/templating/wiki/Naming-and-default-value-forms. Source name may be removed if replacement for name is not required.", + "$comment_sourceName": "TODO: Source name should follow these rules: https://github.com/dotnet/templating/wiki/Naming-and-default-value-forms. Source name may be removed if replacement for name is not required.", "sourceName": "New.Template.1", "preferNameDirectory": true, "symbols": { - "_comment": "TODO: The symbols section defines variables and their values. For more details, see https://github.com/dotnet/templating/wiki/Reference-for-template.json#symbols.", + "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://github.com/dotnet/templating/wiki/Reference-for-template.json#symbols.", "ExampleParameter":{ "type": "parameter", "datatype": "string", @@ -30,20 +30,20 @@ }, "sources": [ { - "_comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property." + "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property." } ], "constraints": { - "_comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property." + "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property." }, "primaryOutputs": [ { - "_comment": "TODO: Primary outputs define the list of template files for further processing, usually post actions. If primary outputs are not required, remove the property." + "$comment": "TODO: Primary outputs define the list of template files for further processing, usually post actions. If primary outputs are not required, remove the property." } ], "postActions": [ { - "_comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property." + "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property." } ] } From 5efe17eb270b40d739eb5b2891de8c7c93420228 Mon Sep 17 00:00:00 2001 From: Vlada Shubina Date: Thu, 8 Dec 2022 16:23:30 +0100 Subject: [PATCH 3/9] removed extra readme --- .../content/README.md | 7 ------- 1 file changed, 7 deletions(-) delete mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/README.md diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/README.md b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/README.md deleted file mode 100644 index 1c373af9dac..00000000000 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/README.md +++ /dev/null @@ -1,7 +0,0 @@ -## The templates for template authoring - -The project contains the templates useful for the template authoring: -| Template name | Short name | Description | -|---|---|---| -|`template.json` configuration file|`template.json`|A template for template.json configuration file for .NET template.| -|Template Package|`template-package`|A project for template package containing .NET templates.| From 62b03c3a031f7b002ad449c9f06cc67037c4aa73 Mon Sep 17 00:00:00 2001 From: Vlada Shubina Date: Fri, 16 Dec 2022 16:11:03 +0100 Subject: [PATCH 4/9] added tests --- Directory.Build.props | 3 +- Microsoft.TemplateEngine.sln | 15 ++ .../.template.config/template.json | 4 + .../content/TemplateJson/template.json | 30 ++- .../.template.config/template.json | 2 +- .../New.Template.Package.csproj | 8 +- .../place_the_template_content_here | 0 .../content/SampleTemplate/placeholder.txt | 1 + .../AuthoringTemplatesTests.cs | 180 ++++++++++++++++++ ...uthoring.Templates.IntegrationTests.csproj | 26 +++ .../.template.config/template.json | 69 +++++++ .../template.json/template.json | 69 +++++++ .../.template.config/template.json | 69 +++++++ .../content/SampleTemplate/placeholder.txt | 1 + .../templatepack/templatepack.csproj | 32 ++++ .../content/SampleTemplate/placeholder.txt | 1 + .../templatepack/templatepack.csproj | 24 +++ .../templatepack/MyTemplatePackage.csproj | 32 ++++ .../content/SampleTemplate/placeholder.txt | 1 + test/Shared/TestBase.cs | 2 + 20 files changed, 558 insertions(+), 11 deletions(-) delete mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/content/SampleTemplate/place_the_template_content_here create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/content/SampleTemplate/placeholder.txt create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/AuthoringTemplatesTests.cs create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests.csproj create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/content/SampleTemplate/placeholder.txt create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/templatepack.csproj create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/content/SampleTemplate/placeholder.txt create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/templatepack.csproj create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/MyTemplatePackage.csproj create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/content/SampleTemplate/placeholder.txt diff --git a/Directory.Build.props b/Directory.Build.props index 68acae33ded..ae45e4f5aca 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -25,8 +25,7 @@ $(RepoRoot)tools\ $(RepoRoot).tools\ $(RepoRoot)localize\ - $(ArtifactsDir)templates\ - $(ArtifactsDir)templates-notimestamp\ + $(RepoRoot)template_feed\ $(RepoRoot)src\ $(RepoRoot)test\ MicrosoftAspNetCore diff --git a/Microsoft.TemplateEngine.sln b/Microsoft.TemplateEngine.sln index 4db383347b5..7c5bf7aa80b 100644 --- a/Microsoft.TemplateEngine.sln +++ b/Microsoft.TemplateEngine.sln @@ -110,6 +110,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "template-feed", "template-f EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.TemplateEngine.Authoring.Templates", "template_feed\Microsoft.TemplateEngine.Authoring.Templates\Microsoft.TemplateEngine.Authoring.Templates.csproj", "{1F74F8F5-99E4-47AE-8608-6D470325E81C}" EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests", "test\Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests\Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests.csproj", "{8651DEEB-0291-4E49-92AA-3B097DAF9D37}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -516,6 +518,18 @@ Global {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Release|x64.Build.0 = Release|Any CPU {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Release|x86.ActiveCfg = Release|Any CPU {1F74F8F5-99E4-47AE-8608-6D470325E81C}.Release|x86.Build.0 = Release|Any CPU + {8651DEEB-0291-4E49-92AA-3B097DAF9D37}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {8651DEEB-0291-4E49-92AA-3B097DAF9D37}.Debug|Any CPU.Build.0 = Debug|Any CPU + {8651DEEB-0291-4E49-92AA-3B097DAF9D37}.Debug|x64.ActiveCfg = Debug|Any CPU + {8651DEEB-0291-4E49-92AA-3B097DAF9D37}.Debug|x64.Build.0 = Debug|Any CPU + {8651DEEB-0291-4E49-92AA-3B097DAF9D37}.Debug|x86.ActiveCfg = Debug|Any CPU + {8651DEEB-0291-4E49-92AA-3B097DAF9D37}.Debug|x86.Build.0 = Debug|Any CPU + {8651DEEB-0291-4E49-92AA-3B097DAF9D37}.Release|Any CPU.ActiveCfg = Release|Any CPU + {8651DEEB-0291-4E49-92AA-3B097DAF9D37}.Release|Any CPU.Build.0 = Release|Any CPU + {8651DEEB-0291-4E49-92AA-3B097DAF9D37}.Release|x64.ActiveCfg = Release|Any CPU + {8651DEEB-0291-4E49-92AA-3B097DAF9D37}.Release|x64.Build.0 = Release|Any CPU + {8651DEEB-0291-4E49-92AA-3B097DAF9D37}.Release|x86.ActiveCfg = Release|Any CPU + {8651DEEB-0291-4E49-92AA-3B097DAF9D37}.Release|x86.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -557,6 +571,7 @@ Global {449B9DDA-F18C-411E-9A74-3930652BB78A} = {B794BF86-4185-4DCE-AC86-C27D5D966B9B} {DFB06A25-719F-4C8B-B84D-55D2D601BEF6} = {3A2D12C2-0455-4471-9EBB-91749BA3A60F} {1F74F8F5-99E4-47AE-8608-6D470325E81C} = {FF433F83-22C2-46E0-99B3-4FFCA5190A94} + {8651DEEB-0291-4E49-92AA-3B097DAF9D37} = {8B498D0C-F488-4B38-8A7D-B20BF9DB6F60} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {6EA1A508-6033-4538-BF98-7F71B4E297AD} diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/template.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/template.json index 98a3b5b183d..389d01f621f 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/template.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/template.json @@ -52,6 +52,10 @@ { "condition": "CreateTemplateConfigFolder == true", "target": ".template.config/" + }, + { + "condition": "CreateTemplateConfigFolder == false", + "target": "./" } ], "primaryOutputs": [ diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json index 6b7e60774d4..dfd957e1a20 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json @@ -1,6 +1,6 @@ { "$schema": "http://json.schemastore.org/template", - "$comment": "See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description. Complete TODOs below and remove the _comment properties.It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", + "$comment": "See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", "author": "TODO: fill author name here.", "classifications": [ "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." @@ -19,8 +19,8 @@ "sourceName": "New.Template.1", "preferNameDirectory": true, "symbols": { - "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://github.com/dotnet/templating/wiki/Reference-for-template.json#symbols.", - "ExampleParameter":{ + "ExampleParameter": { + "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://github.com/dotnet/templating/wiki/Reference-for-template.json#symbols.", "type": "parameter", "datatype": "string", "defaultValue": "example", @@ -31,19 +31,39 @@ "sources": [ { "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property." + "condition": "false", + "source": "./source-files", + "target": "./target" } ], "constraints": { - "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property." + "SampleConstraint": { + "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property.", + "type": "os", + "args": [ "Linux", "OSX", "Windows"] + } }, "primaryOutputs": [ { - "$comment": "TODO: Primary outputs define the list of template files for further processing, usually post actions. If primary outputs are not required, remove the property." + "$comment": "TODO: Primary outputs define the list of template files for further processing, usually post actions. If primary outputs are not required, remove the property.", + "path": "New.Template.1.cs", + "condition": "false" } ], "postActions": [ { "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property." + "actionId": "84C0DA21-51C8-4541-9940-6CA19AF04EE6", + "condition": "false", + "id": "sample-post-action", + "manualInstructions": [ + { + "text": "Open file in New.Template.1.cs in the editor." + } + ], + "args": { + "files": "0" + } } ] } diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json index f5c177a2442..3c92dc51c03 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json @@ -10,7 +10,7 @@ "groupIdentity": "Microsoft.TemplateEngine.Authoring.TemplatePackage", "precedence": "0", "identity": "Microsoft.TemplateEngine.Authoring.TemplatePackage.1.0", - "shortName": "template-package", + "shortName": "templatepack", "tags": { "type": "project" }, diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj index 9d0b22b8520..52bf0c73a6a 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj @@ -16,17 +16,19 @@ true - + + false - + + - \ No newline at end of file + diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/content/SampleTemplate/place_the_template_content_here b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/content/SampleTemplate/place_the_template_content_here deleted file mode 100644 index e69de29bb2d..00000000000 diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/content/SampleTemplate/placeholder.txt b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/content/SampleTemplate/placeholder.txt new file mode 100644 index 00000000000..6f0c602d38e --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/content/SampleTemplate/placeholder.txt @@ -0,0 +1 @@ +Place your templates to this folder. diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/AuthoringTemplatesTests.cs b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/AuthoringTemplatesTests.cs new file mode 100644 index 00000000000..04a4f42173b --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/AuthoringTemplatesTests.cs @@ -0,0 +1,180 @@ +// Licensed to the .NET Foundation under one or more agreements. +// The .NET Foundation licenses this file to you under the MIT license. + +using Microsoft.Extensions.Logging; +using Microsoft.TemplateEngine.Authoring.TemplateApiVerifier; +using Microsoft.TemplateEngine.Authoring.TemplateVerifier; +using Microsoft.TemplateEngine.TestHelper; +using Microsoft.TemplateEngine.Tests; +using Xunit.Abstractions; + +namespace Microsoft.TemplateEngine.Authoring.Templates.Tests +{ + public class AuthoringTemplatesTests : TestBase + { + private readonly ILogger _log; + + public AuthoringTemplatesTests(ITestOutputHelper log) + { + _log = new XunitLoggerProvider(log).CreateLogger("TestRun"); + } + + [Fact] + public async Task TemplateJsonTest() + { + string workingDir = TestUtils.CreateTemporaryFolder(); + string templateShortName = "template.json"; + + //get the template location + string templateLocation = Path.Combine(TemplateFeedLocation, "Microsoft.TemplateEngine.Authoring.Templates"); + + TemplateVerifierOptions options = new TemplateVerifierOptions(templateName: templateShortName) + { + TemplatePath = templateLocation, + SnapshotsDirectory = "Snapshots", + OutputDirectory = workingDir, + DoNotPrependCallerMethodNameToScenarioName = true, + ScenarioName = "Basic", + } + .WithInstantiationThroughTemplateCreatorApi(new Dictionary()); + VerificationEngine engine = new VerificationEngine(_log); + await engine.Execute(options); + } + + [Fact] + public async Task TemplateJsonTest_WithParameters() + { + string workingDir = TestUtils.CreateTemporaryFolder(); + string templateShortName = "template.json"; + + //get the template location + string templateLocation = Path.Combine(TemplateFeedLocation, "Microsoft.TemplateEngine.Authoring.Templates"); + + var templateParams = new Dictionary() + { + { "TemplateName", "MyTemplate" }, + { "TemplateShortName", "mytemplate" }, + { "TemplateIdentity", "My.Template.Identity" }, + }; + + TemplateVerifierOptions options = new TemplateVerifierOptions(templateName: templateShortName) + { + TemplatePath = templateLocation, + SnapshotsDirectory = "Snapshots", + OutputDirectory = workingDir, + DoNotPrependCallerMethodNameToScenarioName = true, + ScenarioName = "WithParams", + } + .WithInstantiationThroughTemplateCreatorApi(templateParams); + + VerificationEngine engine = new VerificationEngine(_log); + await engine.Execute(options); + } + + [Fact] + public async Task TemplateJsonTest_NoConfigFolder() + { + string workingDir = TestUtils.CreateTemporaryFolder(); + string templateShortName = "template.json"; + + //get the template location + string templateLocation = Path.Combine(TemplateFeedLocation, "Microsoft.TemplateEngine.Authoring.Templates"); + + var templateParams = new Dictionary() + { + { "CreateTemplateConfigFolder", "false" } + }; + + TemplateVerifierOptions options = new TemplateVerifierOptions(templateName: templateShortName) + { + TemplatePath = templateLocation, + SnapshotsDirectory = "Snapshots", + OutputDirectory = workingDir, + DoNotPrependCallerMethodNameToScenarioName = true, + ScenarioName = "NoConfigFolder", + } + .WithInstantiationThroughTemplateCreatorApi(templateParams); + + VerificationEngine engine = new VerificationEngine(_log); + await engine.Execute(options); + } + + [Fact] + public async Task TemplatePackageTest() + { + string workingDir = TestUtils.CreateTemporaryFolder(); + string templateShortName = "templatepack"; + + //get the template location + string templateLocation = Path.Combine(TemplateFeedLocation, "Microsoft.TemplateEngine.Authoring.Templates"); + + TemplateVerifierOptions options = new TemplateVerifierOptions(templateName: templateShortName) + { + TemplatePath = templateLocation, + SnapshotsDirectory = "Snapshots", + OutputDirectory = workingDir, + DoNotPrependCallerMethodNameToScenarioName = true, + ScenarioName = "Basic", + } + .WithInstantiationThroughTemplateCreatorApi(new Dictionary()); + VerificationEngine engine = new VerificationEngine(_log); + await engine.Execute(options); + } + + [Fact] + public async Task TemplatePackageTest_WithName() + { + string workingDir = TestUtils.CreateTemporaryFolder(); + string templateShortName = "templatepack"; + + //get the template location + string templateLocation = Path.Combine(TemplateFeedLocation, "Microsoft.TemplateEngine.Authoring.Templates"); + + var templateParams = new Dictionary() + { + { "name", "MyTemplatePackage" }, + }; + + TemplateVerifierOptions options = new TemplateVerifierOptions(templateName: templateShortName) + { + TemplatePath = templateLocation, + SnapshotsDirectory = "Snapshots", + OutputDirectory = workingDir, + DoNotPrependCallerMethodNameToScenarioName = true, + ScenarioName = "WithName", + } + .WithInstantiationThroughTemplateCreatorApi(templateParams); + + VerificationEngine engine = new VerificationEngine(_log); + await engine.Execute(options); + } + + [Fact] + public async Task TemplatePackageTest_NoMSBuildTasks() + { + string workingDir = TestUtils.CreateTemporaryFolder(); + string templateShortName = "templatepack"; + + //get the template location + string templateLocation = Path.Combine(TemplateFeedLocation, "Microsoft.TemplateEngine.Authoring.Templates"); + + var templateParams = new Dictionary() + { + { "EnableMSBuildTasks", "false" }, + }; + + TemplateVerifierOptions options = new TemplateVerifierOptions(templateName: templateShortName) + { + TemplatePath = templateLocation, + SnapshotsDirectory = "Snapshots", + OutputDirectory = workingDir, + DoNotPrependCallerMethodNameToScenarioName = true, + ScenarioName = "NoMSBuildTasks", + } + .WithInstantiationThroughTemplateCreatorApi(templateParams); + + VerificationEngine engine = new VerificationEngine(_log); + await engine.Execute(options); + } + } +} diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests.csproj b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests.csproj new file mode 100644 index 00000000000..46bd7b29d14 --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests.csproj @@ -0,0 +1,26 @@ + + + + $(NETCoreTargetFramework) + enable + enable + false + + + + + + + + + + + + + + + + + + + diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json new file mode 100644 index 00000000000..a5a7ace2cc8 --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json @@ -0,0 +1,69 @@ +{ + "$schema": "http://json.schemastore.org/template", + "$comment": "See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", + "author": "TODO: fill author name here.", + "classifications": [ + "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." + ], + "name": "New Template", + "description": "TODO: fill the template description here.", + "precedence": "0", + "identity": "New.Template.Identity", + "shortName": "new-template", + "tags": { + "$comment": "TODO: fill the language and type below. Common types are: project, item, solution.", + "language": "C#", + "type": "project" + }, + "$comment_sourceName": "TODO: Source name should follow these rules: https://github.com/dotnet/templating/wiki/Naming-and-default-value-forms. Source name may be removed if replacement for name is not required.", + "sourceName": "New.Template.1", + "preferNameDirectory": true, + "symbols": { + "ExampleParameter": { + "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://github.com/dotnet/templating/wiki/Reference-for-template.json#symbols.", + "type": "parameter", + "datatype": "string", + "defaultValue": "example", + "replaces": "valueToReplace", + "isEnabled": false + } + }, + "sources": [ + { + "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property." + "condition": "false", + "source": "./source-files", + "target": "./target" + } + ], + "constraints": { + "SampleConstraint": { + "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property.", + "type": "os", + "args": [ "Linux", "OSX", "Windows"] + } + }, + "primaryOutputs": [ + { + "$comment": "TODO: Primary outputs define the list of template files for further processing, usually post actions. If primary outputs are not required, remove the property.", + "path": "New.Template.1.cs", + "condition": "false" + } + ], + "postActions": [ + { + "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property." + "actionId": "84C0DA21-51C8-4541-9940-6CA19AF04EE6", + "condition": "false", + "id": "sample-post-action", + "manualInstructions": [ + { + "text": "Open file in New.Template.1.cs in the editor." + } + ], + "args": { + "files": "0" + } + } + ] +} diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json new file mode 100644 index 00000000000..a5a7ace2cc8 --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json @@ -0,0 +1,69 @@ +{ + "$schema": "http://json.schemastore.org/template", + "$comment": "See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", + "author": "TODO: fill author name here.", + "classifications": [ + "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." + ], + "name": "New Template", + "description": "TODO: fill the template description here.", + "precedence": "0", + "identity": "New.Template.Identity", + "shortName": "new-template", + "tags": { + "$comment": "TODO: fill the language and type below. Common types are: project, item, solution.", + "language": "C#", + "type": "project" + }, + "$comment_sourceName": "TODO: Source name should follow these rules: https://github.com/dotnet/templating/wiki/Naming-and-default-value-forms. Source name may be removed if replacement for name is not required.", + "sourceName": "New.Template.1", + "preferNameDirectory": true, + "symbols": { + "ExampleParameter": { + "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://github.com/dotnet/templating/wiki/Reference-for-template.json#symbols.", + "type": "parameter", + "datatype": "string", + "defaultValue": "example", + "replaces": "valueToReplace", + "isEnabled": false + } + }, + "sources": [ + { + "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property." + "condition": "false", + "source": "./source-files", + "target": "./target" + } + ], + "constraints": { + "SampleConstraint": { + "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property.", + "type": "os", + "args": [ "Linux", "OSX", "Windows"] + } + }, + "primaryOutputs": [ + { + "$comment": "TODO: Primary outputs define the list of template files for further processing, usually post actions. If primary outputs are not required, remove the property.", + "path": "New.Template.1.cs", + "condition": "false" + } + ], + "postActions": [ + { + "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property." + "actionId": "84C0DA21-51C8-4541-9940-6CA19AF04EE6", + "condition": "false", + "id": "sample-post-action", + "manualInstructions": [ + { + "text": "Open file in New.Template.1.cs in the editor." + } + ], + "args": { + "files": "0" + } + } + ] +} diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json new file mode 100644 index 00000000000..41ffb64316b --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json @@ -0,0 +1,69 @@ +{ + "$schema": "http://json.schemastore.org/template", + "$comment": "See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", + "author": "TODO: fill author name here.", + "classifications": [ + "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." + ], + "name": "MyTemplate", + "description": "TODO: fill the template description here.", + "precedence": "0", + "identity": "My.Template.Identity", + "shortName": "mytemplate", + "tags": { + "$comment": "TODO: fill the language and type below. Common types are: project, item, solution.", + "language": "C#", + "type": "project" + }, + "$comment_sourceName": "TODO: Source name should follow these rules: https://github.com/dotnet/templating/wiki/Naming-and-default-value-forms. Source name may be removed if replacement for name is not required.", + "sourceName": "New.Template.1", + "preferNameDirectory": true, + "symbols": { + "ExampleParameter": { + "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://github.com/dotnet/templating/wiki/Reference-for-template.json#symbols.", + "type": "parameter", + "datatype": "string", + "defaultValue": "example", + "replaces": "valueToReplace", + "isEnabled": false + } + }, + "sources": [ + { + "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property." + "condition": "false", + "source": "./source-files", + "target": "./target" + } + ], + "constraints": { + "SampleConstraint": { + "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property.", + "type": "os", + "args": [ "Linux", "OSX", "Windows"] + } + }, + "primaryOutputs": [ + { + "$comment": "TODO: Primary outputs define the list of template files for further processing, usually post actions. If primary outputs are not required, remove the property.", + "path": "New.Template.1.cs", + "condition": "false" + } + ], + "postActions": [ + { + "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property." + "actionId": "84C0DA21-51C8-4541-9940-6CA19AF04EE6", + "condition": "false", + "id": "sample-post-action", + "manualInstructions": [ + { + "text": "Open file in New.Template.1.cs in the editor." + } + ], + "args": { + "files": "0" + } + } + ] +} diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/content/SampleTemplate/placeholder.txt b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/content/SampleTemplate/placeholder.txt new file mode 100644 index 00000000000..5c9d9e9116a --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/content/SampleTemplate/placeholder.txt @@ -0,0 +1 @@ +Place your templates to this folder. diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/templatepack.csproj b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/templatepack.csproj new file mode 100644 index 00000000000..e73babd33fa --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/templatepack.csproj @@ -0,0 +1,32 @@ + + + + Template + 1.0 + templatepack + TODO: fill the package name here + Me + TODO: fill the package description here + dotnet-new;templates + net7.0 + true + false + content + $(NoWarn);NU5128 + true + + + + false + + + + + + + + + + + + diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/content/SampleTemplate/placeholder.txt b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/content/SampleTemplate/placeholder.txt new file mode 100644 index 00000000000..5c9d9e9116a --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/content/SampleTemplate/placeholder.txt @@ -0,0 +1 @@ +Place your templates to this folder. diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/templatepack.csproj b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/templatepack.csproj new file mode 100644 index 00000000000..9ebb3f4bffc --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/templatepack.csproj @@ -0,0 +1,24 @@ + + + + Template + 1.0 + templatepack + TODO: fill the package name here + Me + TODO: fill the package description here + dotnet-new;templates + net7.0 + true + false + content + $(NoWarn);NU5128 + true + + + + + + + + diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/MyTemplatePackage.csproj b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/MyTemplatePackage.csproj new file mode 100644 index 00000000000..a4906c715e2 --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/MyTemplatePackage.csproj @@ -0,0 +1,32 @@ + + + + Template + 1.0 + MyTemplatePackage + TODO: fill the package name here + Me + TODO: fill the package description here + dotnet-new;templates + net7.0 + true + false + content + $(NoWarn);NU5128 + true + + + + false + + + + + + + + + + + + diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/content/SampleTemplate/placeholder.txt b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/content/SampleTemplate/placeholder.txt new file mode 100644 index 00000000000..5c9d9e9116a --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/content/SampleTemplate/placeholder.txt @@ -0,0 +1 @@ +Place your templates to this folder. diff --git a/test/Shared/TestBase.cs b/test/Shared/TestBase.cs index 065a23b66b7..165bfb9d63e 100644 --- a/test/Shared/TestBase.cs +++ b/test/Shared/TestBase.cs @@ -38,6 +38,8 @@ internal static string ShippingPackagesLocation } } + internal static string TemplateFeedLocation { get; } = Path.Combine(CodeBaseRoot, "template_feed"); + internal static string TestTemplatesLocation { get; } = Path.Combine(CodeBaseRoot, "test", "Microsoft.TemplateEngine.TestTemplates", "test_templates"); internal static string TestTemplatePackagesLocation { get; } = Path.Combine(CodeBaseRoot, "test", "Microsoft.TemplateEngine.TestTemplates", "nupkg_templates"); From 1f43d4bf7e86d889464072388ac3d5ea4f6e3d4f Mon Sep 17 00:00:00 2001 From: Vlada Shubina Date: Mon, 19 Dec 2022 16:13:55 +0100 Subject: [PATCH 5/9] added TODO instructions using post action --- ....TemplateEngine.Authoring.Templates.csproj | 3 + .../localize/templatestrings.cs.json | 4 +- .../localize/templatestrings.de.json | 4 +- .../localize/templatestrings.en.json | 4 +- .../localize/templatestrings.es.json | 4 +- .../localize/templatestrings.fr.json | 4 +- .../localize/templatestrings.it.json | 4 +- .../localize/templatestrings.ja.json | 4 +- .../localize/templatestrings.ko.json | 4 +- .../localize/templatestrings.pl.json | 4 +- .../localize/templatestrings.pt-BR.json | 4 +- .../localize/templatestrings.ru.json | 4 +- .../localize/templatestrings.tr.json | 4 +- .../localize/templatestrings.zh-Hans.json | 4 +- .../localize/templatestrings.zh-Hant.json | 4 +- .../.template.config/template.json | 13 ++++ .../content/TemplateJson/template.json | 6 +- .../localize/templatestrings.cs.json | 4 +- .../localize/templatestrings.de.json | 4 +- .../localize/templatestrings.en.json | 4 +- .../localize/templatestrings.es.json | 4 +- .../localize/templatestrings.fr.json | 4 +- .../localize/templatestrings.it.json | 4 +- .../localize/templatestrings.ja.json | 4 +- .../localize/templatestrings.ko.json | 4 +- .../localize/templatestrings.pl.json | 4 +- .../localize/templatestrings.pt-BR.json | 4 +- .../localize/templatestrings.ru.json | 4 +- .../localize/templatestrings.tr.json | 4 +- .../localize/templatestrings.zh-Hans.json | 4 +- .../localize/templatestrings.zh-Hant.json | 4 +- .../.template.config/template.json | 16 ++++- .../AuthoringTemplatesTests.cs | 44 ++++++++++++ ...uthoring.Templates.IntegrationTests.csproj | 4 ++ .../.template.config/template.json | 6 +- .../std-streams/stderr.txt | 1 + .../std-streams/stdout.txt | 5 ++ .../.template.config/template.json | 69 +++++++++++++++++++ .../template.json/template.json | 6 +- .../.template.config/template.json | 6 +- .../std-streams/stderr.txt | 1 + .../std-streams/stdout.txt | 5 ++ .../content/SampleTemplate/placeholder.txt | 1 + .../templatepack/templatepack.csproj | 32 +++++++++ 44 files changed, 288 insertions(+), 42 deletions(-) create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/std-streams/stderr.txt create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/std-streams/stdout.txt create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/template.json/.template.config/template.json create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/std-streams/stderr.txt create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/std-streams/stdout.txt create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/content/SampleTemplate/placeholder.txt create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/templatepack.csproj diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/Microsoft.TemplateEngine.Authoring.Templates.csproj b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/Microsoft.TemplateEngine.Authoring.Templates.csproj index d79baa62a79..890ec4205b9 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/Microsoft.TemplateEngine.Authoring.Templates.csproj +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/Microsoft.TemplateEngine.Authoring.Templates.csproj @@ -32,4 +32,7 @@ + + + diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.cs.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.cs.json index 25c1290652e..8fad34c4c10 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.cs.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.cs.json @@ -9,5 +9,7 @@ "symbols/TemplateShortName/description": "The template short name.", "symbols/TemplateShortName/displayName": "Template short name", "symbols/TemplateIdentity/description": "The template identity (should be unique).", - "symbols/TemplateIdentity/displayName": "Template identity" + "symbols/TemplateIdentity/displayName": "Template identity", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open template.json in the editor and complete the configuration." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.de.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.de.json index 25c1290652e..8fad34c4c10 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.de.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.de.json @@ -9,5 +9,7 @@ "symbols/TemplateShortName/description": "The template short name.", "symbols/TemplateShortName/displayName": "Template short name", "symbols/TemplateIdentity/description": "The template identity (should be unique).", - "symbols/TemplateIdentity/displayName": "Template identity" + "symbols/TemplateIdentity/displayName": "Template identity", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open template.json in the editor and complete the configuration." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.en.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.en.json index f8f9ad21eb6..d1727507ff0 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.en.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.en.json @@ -9,5 +9,7 @@ "symbols/TemplateShortName/description": "The template short name.", "symbols/TemplateShortName/displayName": "Template short name", "symbols/TemplateIdentity/description": "The template identity (should be unique).", - "symbols/TemplateIdentity/displayName": "Template identity" + "symbols/TemplateIdentity/displayName": "Template identity", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open template.json in the editor and complete the configuration." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.es.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.es.json index 25c1290652e..8fad34c4c10 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.es.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.es.json @@ -9,5 +9,7 @@ "symbols/TemplateShortName/description": "The template short name.", "symbols/TemplateShortName/displayName": "Template short name", "symbols/TemplateIdentity/description": "The template identity (should be unique).", - "symbols/TemplateIdentity/displayName": "Template identity" + "symbols/TemplateIdentity/displayName": "Template identity", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open template.json in the editor and complete the configuration." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.fr.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.fr.json index 25c1290652e..8fad34c4c10 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.fr.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.fr.json @@ -9,5 +9,7 @@ "symbols/TemplateShortName/description": "The template short name.", "symbols/TemplateShortName/displayName": "Template short name", "symbols/TemplateIdentity/description": "The template identity (should be unique).", - "symbols/TemplateIdentity/displayName": "Template identity" + "symbols/TemplateIdentity/displayName": "Template identity", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open template.json in the editor and complete the configuration." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.it.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.it.json index 25c1290652e..8fad34c4c10 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.it.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.it.json @@ -9,5 +9,7 @@ "symbols/TemplateShortName/description": "The template short name.", "symbols/TemplateShortName/displayName": "Template short name", "symbols/TemplateIdentity/description": "The template identity (should be unique).", - "symbols/TemplateIdentity/displayName": "Template identity" + "symbols/TemplateIdentity/displayName": "Template identity", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open template.json in the editor and complete the configuration." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ja.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ja.json index 25c1290652e..8fad34c4c10 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ja.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ja.json @@ -9,5 +9,7 @@ "symbols/TemplateShortName/description": "The template short name.", "symbols/TemplateShortName/displayName": "Template short name", "symbols/TemplateIdentity/description": "The template identity (should be unique).", - "symbols/TemplateIdentity/displayName": "Template identity" + "symbols/TemplateIdentity/displayName": "Template identity", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open template.json in the editor and complete the configuration." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ko.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ko.json index 25c1290652e..8fad34c4c10 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ko.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ko.json @@ -9,5 +9,7 @@ "symbols/TemplateShortName/description": "The template short name.", "symbols/TemplateShortName/displayName": "Template short name", "symbols/TemplateIdentity/description": "The template identity (should be unique).", - "symbols/TemplateIdentity/displayName": "Template identity" + "symbols/TemplateIdentity/displayName": "Template identity", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open template.json in the editor and complete the configuration." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pl.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pl.json index 25c1290652e..8fad34c4c10 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pl.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pl.json @@ -9,5 +9,7 @@ "symbols/TemplateShortName/description": "The template short name.", "symbols/TemplateShortName/displayName": "Template short name", "symbols/TemplateIdentity/description": "The template identity (should be unique).", - "symbols/TemplateIdentity/displayName": "Template identity" + "symbols/TemplateIdentity/displayName": "Template identity", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open template.json in the editor and complete the configuration." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pt-BR.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pt-BR.json index 25c1290652e..8fad34c4c10 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pt-BR.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.pt-BR.json @@ -9,5 +9,7 @@ "symbols/TemplateShortName/description": "The template short name.", "symbols/TemplateShortName/displayName": "Template short name", "symbols/TemplateIdentity/description": "The template identity (should be unique).", - "symbols/TemplateIdentity/displayName": "Template identity" + "symbols/TemplateIdentity/displayName": "Template identity", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open template.json in the editor and complete the configuration." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ru.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ru.json index 25c1290652e..8fad34c4c10 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ru.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.ru.json @@ -9,5 +9,7 @@ "symbols/TemplateShortName/description": "The template short name.", "symbols/TemplateShortName/displayName": "Template short name", "symbols/TemplateIdentity/description": "The template identity (should be unique).", - "symbols/TemplateIdentity/displayName": "Template identity" + "symbols/TemplateIdentity/displayName": "Template identity", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open template.json in the editor and complete the configuration." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.tr.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.tr.json index 25c1290652e..8fad34c4c10 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.tr.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.tr.json @@ -9,5 +9,7 @@ "symbols/TemplateShortName/description": "The template short name.", "symbols/TemplateShortName/displayName": "Template short name", "symbols/TemplateIdentity/description": "The template identity (should be unique).", - "symbols/TemplateIdentity/displayName": "Template identity" + "symbols/TemplateIdentity/displayName": "Template identity", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open template.json in the editor and complete the configuration." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hans.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hans.json index 25c1290652e..8fad34c4c10 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hans.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hans.json @@ -9,5 +9,7 @@ "symbols/TemplateShortName/description": "The template short name.", "symbols/TemplateShortName/displayName": "Template short name", "symbols/TemplateIdentity/description": "The template identity (should be unique).", - "symbols/TemplateIdentity/displayName": "Template identity" + "symbols/TemplateIdentity/displayName": "Template identity", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open template.json in the editor and complete the configuration." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hant.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hant.json index 25c1290652e..8fad34c4c10 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hant.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/localize/templatestrings.zh-Hant.json @@ -9,5 +9,7 @@ "symbols/TemplateShortName/description": "The template short name.", "symbols/TemplateShortName/displayName": "Template short name", "symbols/TemplateIdentity/description": "The template identity (should be unique).", - "symbols/TemplateIdentity/displayName": "Template identity" + "symbols/TemplateIdentity/displayName": "Template identity", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open template.json in the editor and complete the configuration." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/template.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/template.json index 389d01f621f..d1594f23a2f 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/template.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/.template.config/template.json @@ -67,5 +67,18 @@ "condition": "CreateTemplateConfigFolder != true", "path": "template.json" } + ], + "postActions": [ + { + "id": "instructions", + "description": "Manual actions required", + "manualInstructions": [ + { + "text": "Open template.json in the editor and complete the configuration." + } + ], + "actionId": "AC1156F7-BB77-4DB8-B28F-24EEBCCA1E5C", + "continueOnError": true + } ] } diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json index dfd957e1a20..ff7bb6d427c 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json @@ -30,7 +30,7 @@ }, "sources": [ { - "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property." + "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property.", "condition": "false", "source": "./source-files", "target": "./target" @@ -40,7 +40,7 @@ "SampleConstraint": { "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property.", "type": "os", - "args": [ "Linux", "OSX", "Windows"] + "args": [ "Linux", "OSX", "Windows" ] } }, "primaryOutputs": [ @@ -52,7 +52,7 @@ ], "postActions": [ { - "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property." + "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property.", "actionId": "84C0DA21-51C8-4541-9940-6CA19AF04EE6", "condition": "false", "id": "sample-post-action", diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.cs.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.cs.json index 9b1b2aebb84..571cf3fe3fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.cs.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.cs.json @@ -1,5 +1,7 @@ { "author": "Microsoft", "name": "Template Package", - "description": "A project for creating template package containing .NET templates." + "description": "A project for a template package containing .NET templates.", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.de.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.de.json index 9b1b2aebb84..571cf3fe3fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.de.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.de.json @@ -1,5 +1,7 @@ { "author": "Microsoft", "name": "Template Package", - "description": "A project for creating template package containing .NET templates." + "description": "A project for a template package containing .NET templates.", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.en.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.en.json index 500d4bac663..571cf3fe3fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.en.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.en.json @@ -1,5 +1,7 @@ { "author": "Microsoft", "name": "Template Package", - "description": "A project for a template package containing .NET templates." + "description": "A project for a template package containing .NET templates.", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.es.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.es.json index 9b1b2aebb84..571cf3fe3fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.es.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.es.json @@ -1,5 +1,7 @@ { "author": "Microsoft", "name": "Template Package", - "description": "A project for creating template package containing .NET templates." + "description": "A project for a template package containing .NET templates.", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.fr.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.fr.json index 9b1b2aebb84..571cf3fe3fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.fr.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.fr.json @@ -1,5 +1,7 @@ { "author": "Microsoft", "name": "Template Package", - "description": "A project for creating template package containing .NET templates." + "description": "A project for a template package containing .NET templates.", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.it.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.it.json index 9b1b2aebb84..571cf3fe3fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.it.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.it.json @@ -1,5 +1,7 @@ { "author": "Microsoft", "name": "Template Package", - "description": "A project for creating template package containing .NET templates." + "description": "A project for a template package containing .NET templates.", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ja.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ja.json index 9b1b2aebb84..571cf3fe3fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ja.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ja.json @@ -1,5 +1,7 @@ { "author": "Microsoft", "name": "Template Package", - "description": "A project for creating template package containing .NET templates." + "description": "A project for a template package containing .NET templates.", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ko.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ko.json index 9b1b2aebb84..571cf3fe3fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ko.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ko.json @@ -1,5 +1,7 @@ { "author": "Microsoft", "name": "Template Package", - "description": "A project for creating template package containing .NET templates." + "description": "A project for a template package containing .NET templates.", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pl.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pl.json index 9b1b2aebb84..571cf3fe3fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pl.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pl.json @@ -1,5 +1,7 @@ { "author": "Microsoft", "name": "Template Package", - "description": "A project for creating template package containing .NET templates." + "description": "A project for a template package containing .NET templates.", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pt-BR.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pt-BR.json index 9b1b2aebb84..571cf3fe3fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pt-BR.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pt-BR.json @@ -1,5 +1,7 @@ { "author": "Microsoft", "name": "Template Package", - "description": "A project for creating template package containing .NET templates." + "description": "A project for a template package containing .NET templates.", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ru.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ru.json index 9b1b2aebb84..571cf3fe3fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ru.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ru.json @@ -1,5 +1,7 @@ { "author": "Microsoft", "name": "Template Package", - "description": "A project for creating template package containing .NET templates." + "description": "A project for a template package containing .NET templates.", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.tr.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.tr.json index 9b1b2aebb84..571cf3fe3fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.tr.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.tr.json @@ -1,5 +1,7 @@ { "author": "Microsoft", "name": "Template Package", - "description": "A project for creating template package containing .NET templates." + "description": "A project for a template package containing .NET templates.", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hans.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hans.json index 9b1b2aebb84..571cf3fe3fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hans.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hans.json @@ -1,5 +1,7 @@ { "author": "Microsoft", "name": "Template Package", - "description": "A project for creating template package containing .NET templates." + "description": "A project for a template package containing .NET templates.", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hant.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hant.json index 9b1b2aebb84..571cf3fe3fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hant.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hant.json @@ -1,5 +1,7 @@ { "author": "Microsoft", "name": "Template Package", - "description": "A project for creating template package containing .NET templates." + "description": "A project for a template package containing .NET templates.", + "postActions/instructions/description": "Manual actions required", + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json index 3c92dc51c03..8ffba029a53 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json @@ -16,8 +16,7 @@ }, "sourceName": "New.Template.Package", "symbols": { - "EnableMSBuildTasks": - { + "EnableMSBuildTasks": { "type": "parameter", "datatype": "bool", "defaultValue": "true" @@ -27,5 +26,18 @@ { "path": "New.Template.Package.csproj" } + ], + "postActions": [ + { + "id": "instructions", + "description": "Manual actions required", + "manualInstructions": [ + { + "text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + } + ], + "actionId": "AC1156F7-BB77-4DB8-B28F-24EEBCCA1E5C", + "continueOnError": true + } ] } diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/AuthoringTemplatesTests.cs b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/AuthoringTemplatesTests.cs index 04a4f42173b..f87a2946758 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/AuthoringTemplatesTests.cs +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/AuthoringTemplatesTests.cs @@ -176,5 +176,49 @@ public async Task TemplatePackageTest_NoMSBuildTasks() VerificationEngine engine = new VerificationEngine(_log); await engine.Execute(options); } + + [Fact] + public async Task TemplateJsonTest_CLI() + { + string workingDir = TestUtils.CreateTemporaryFolder(); + string templateShortName = "template.json"; + + //get the template location + string templateLocation = Path.Combine(TemplateFeedLocation, "Microsoft.TemplateEngine.Authoring.Templates"); + + TemplateVerifierOptions options = new TemplateVerifierOptions(templateName: templateShortName) + { + TemplatePath = templateLocation, + SnapshotsDirectory = "Snapshots", + OutputDirectory = workingDir, + DoNotPrependCallerMethodNameToScenarioName = true, + VerifyCommandOutput = true, + ScenarioName = "CLI", + }; + VerificationEngine engine = new VerificationEngine(_log); + await engine.Execute(options); + } + + [Fact] + public async Task TemplatePackageTest_CLI() + { + string workingDir = TestUtils.CreateTemporaryFolder(); + string templateShortName = "templatepack"; + + //get the template location + string templateLocation = Path.Combine(TemplateFeedLocation, "Microsoft.TemplateEngine.Authoring.Templates"); + + TemplateVerifierOptions options = new TemplateVerifierOptions(templateName: templateShortName) + { + TemplatePath = templateLocation, + SnapshotsDirectory = "Snapshots", + OutputDirectory = workingDir, + DoNotPrependCallerMethodNameToScenarioName = true, + VerifyCommandOutput = true, + ScenarioName = "CLI", + }; + VerificationEngine engine = new VerificationEngine(_log); + await engine.Execute(options); + } } } diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests.csproj b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests.csproj index 46bd7b29d14..7d85d6d3c45 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests.csproj +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests.csproj @@ -23,4 +23,8 @@ + + + + diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json index a5a7ace2cc8..cfd77f26d51 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json @@ -30,7 +30,7 @@ }, "sources": [ { - "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property." + "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property.", "condition": "false", "source": "./source-files", "target": "./target" @@ -40,7 +40,7 @@ "SampleConstraint": { "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property.", "type": "os", - "args": [ "Linux", "OSX", "Windows"] + "args": [ "Linux", "OSX", "Windows" ] } }, "primaryOutputs": [ @@ -52,7 +52,7 @@ ], "postActions": [ { - "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property." + "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property.", "actionId": "84C0DA21-51C8-4541-9940-6CA19AF04EE6", "condition": "false", "id": "sample-post-action", diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/std-streams/stderr.txt b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/std-streams/stderr.txt new file mode 100644 index 00000000000..5f282702bb0 --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/std-streams/stderr.txt @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/std-streams/stdout.txt b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/std-streams/stdout.txt new file mode 100644 index 00000000000..ef0b9b51e7b --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/std-streams/stdout.txt @@ -0,0 +1,5 @@ +The template "template.json configuration file" was created successfully. + +Processing post-creation actions... +Description: Manual actions required +Manual instructions: Open template.json in the editor and complete the configuration. \ No newline at end of file diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/template.json/.template.config/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/template.json/.template.config/template.json new file mode 100644 index 00000000000..cfd77f26d51 --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/template.json/.template.config/template.json @@ -0,0 +1,69 @@ +{ + "$schema": "http://json.schemastore.org/template", + "$comment": "See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", + "author": "TODO: fill author name here.", + "classifications": [ + "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." + ], + "name": "New Template", + "description": "TODO: fill the template description here.", + "precedence": "0", + "identity": "New.Template.Identity", + "shortName": "new-template", + "tags": { + "$comment": "TODO: fill the language and type below. Common types are: project, item, solution.", + "language": "C#", + "type": "project" + }, + "$comment_sourceName": "TODO: Source name should follow these rules: https://github.com/dotnet/templating/wiki/Naming-and-default-value-forms. Source name may be removed if replacement for name is not required.", + "sourceName": "New.Template.1", + "preferNameDirectory": true, + "symbols": { + "ExampleParameter": { + "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://github.com/dotnet/templating/wiki/Reference-for-template.json#symbols.", + "type": "parameter", + "datatype": "string", + "defaultValue": "example", + "replaces": "valueToReplace", + "isEnabled": false + } + }, + "sources": [ + { + "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property.", + "condition": "false", + "source": "./source-files", + "target": "./target" + } + ], + "constraints": { + "SampleConstraint": { + "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property.", + "type": "os", + "args": [ "Linux", "OSX", "Windows" ] + } + }, + "primaryOutputs": [ + { + "$comment": "TODO: Primary outputs define the list of template files for further processing, usually post actions. If primary outputs are not required, remove the property.", + "path": "New.Template.1.cs", + "condition": "false" + } + ], + "postActions": [ + { + "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property.", + "actionId": "84C0DA21-51C8-4541-9940-6CA19AF04EE6", + "condition": "false", + "id": "sample-post-action", + "manualInstructions": [ + { + "text": "Open file in New.Template.1.cs in the editor." + } + ], + "args": { + "files": "0" + } + } + ] +} diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json index a5a7ace2cc8..cfd77f26d51 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json @@ -30,7 +30,7 @@ }, "sources": [ { - "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property." + "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property.", "condition": "false", "source": "./source-files", "target": "./target" @@ -40,7 +40,7 @@ "SampleConstraint": { "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property.", "type": "os", - "args": [ "Linux", "OSX", "Windows"] + "args": [ "Linux", "OSX", "Windows" ] } }, "primaryOutputs": [ @@ -52,7 +52,7 @@ ], "postActions": [ { - "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property." + "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property.", "actionId": "84C0DA21-51C8-4541-9940-6CA19AF04EE6", "condition": "false", "id": "sample-post-action", diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json index 41ffb64316b..d291983f13a 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json @@ -30,7 +30,7 @@ }, "sources": [ { - "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property." + "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property.", "condition": "false", "source": "./source-files", "target": "./target" @@ -40,7 +40,7 @@ "SampleConstraint": { "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property.", "type": "os", - "args": [ "Linux", "OSX", "Windows"] + "args": [ "Linux", "OSX", "Windows" ] } }, "primaryOutputs": [ @@ -52,7 +52,7 @@ ], "postActions": [ { - "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property." + "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property.", "actionId": "84C0DA21-51C8-4541-9940-6CA19AF04EE6", "condition": "false", "id": "sample-post-action", diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/std-streams/stderr.txt b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/std-streams/stderr.txt new file mode 100644 index 00000000000..5f282702bb0 --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/std-streams/stderr.txt @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/std-streams/stdout.txt b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/std-streams/stdout.txt new file mode 100644 index 00000000000..4218c30e9b1 --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/std-streams/stdout.txt @@ -0,0 +1,5 @@ +The template "Template Package" was created successfully. + +Processing post-creation actions... +Description: Manual actions required +Manual instructions: Open *.csproj in the editor and complete the package metadata configuration. \ No newline at end of file diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/content/SampleTemplate/placeholder.txt b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/content/SampleTemplate/placeholder.txt new file mode 100644 index 00000000000..5c9d9e9116a --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/content/SampleTemplate/placeholder.txt @@ -0,0 +1 @@ +Place your templates to this folder. diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/templatepack.csproj b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/templatepack.csproj new file mode 100644 index 00000000000..e73babd33fa --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/templatepack.csproj @@ -0,0 +1,32 @@ + + + + Template + 1.0 + templatepack + TODO: fill the package name here + Me + TODO: fill the package description here + dotnet-new;templates + net7.0 + true + false + content + $(NoWarn);NU5128 + true + + + + false + + + + + + + + + + + + From 2a97d239d4e2e0f27737b63bfb8dd557e20e4433 Mon Sep 17 00:00:00 2001 From: Vlada Shubina Date: Mon, 19 Dec 2022 16:54:01 +0100 Subject: [PATCH 6/9] replaced the links, polishing --- .../content/TemplateJson/template.json | 12 ++-- .../localize/templatestrings.cs.json | 2 +- .../localize/templatestrings.de.json | 2 +- .../localize/templatestrings.en.json | 2 +- .../localize/templatestrings.es.json | 2 +- .../localize/templatestrings.fr.json | 2 +- .../localize/templatestrings.it.json | 2 +- .../localize/templatestrings.ja.json | 2 +- .../localize/templatestrings.ko.json | 2 +- .../localize/templatestrings.pl.json | 2 +- .../localize/templatestrings.pt-BR.json | 2 +- .../localize/templatestrings.ru.json | 2 +- .../localize/templatestrings.tr.json | 2 +- .../localize/templatestrings.zh-Hans.json | 2 +- .../localize/templatestrings.zh-Hant.json | 2 +- .../.template.config/template.json | 2 +- .../New.Template.Package.csproj | 61 ++++++++++--------- .../content/TemplatePackage/README.md | 2 + .../.template.config/template.json | 12 ++-- .../.template.config/template.json | 12 ++-- .../template.json/template.json | 12 ++-- .../.template.config/template.json | 12 ++-- .../templatepack/README.md | 2 + .../templatepack/templatepack.csproj | 59 ++++++++++-------- .../std-streams/stdout.txt | 2 +- .../templatepack/README.md | 2 + .../templatepack/templatepack.csproj | 59 ++++++++++-------- .../templatepack/README.md | 2 + .../templatepack/templatepack.csproj | 47 +++++++------- .../templatepack/MyTemplatePackage.csproj | 59 ++++++++++-------- .../templatepack/README.md | 2 + 31 files changed, 211 insertions(+), 176 deletions(-) create mode 100644 template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/README.md create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/README.md create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/README.md create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/README.md create mode 100644 test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/README.md diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json index ff7bb6d427c..6954498853e 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json @@ -1,6 +1,6 @@ { "$schema": "http://json.schemastore.org/template", - "$comment": "See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", + "$comment": "See https://aka.ms/template-json-reference for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", "author": "TODO: fill author name here.", "classifications": [ "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." @@ -15,12 +15,12 @@ "language": "C#", "type": "project" }, - "$comment_sourceName": "TODO: Source name should follow these rules: https://github.com/dotnet/templating/wiki/Naming-and-default-value-forms. Source name may be removed if replacement for name is not required.", + "$comment_sourceName": "TODO: Source name should follow these rules: https://aka.ms/template-json-source-name. Source name may be removed if replacement for name is not required.", "sourceName": "New.Template.1", "preferNameDirectory": true, "symbols": { "ExampleParameter": { - "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://github.com/dotnet/templating/wiki/Reference-for-template.json#symbols.", + "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://aka.ms/template-json-reference#symbols.", "type": "parameter", "datatype": "string", "defaultValue": "example", @@ -30,7 +30,7 @@ }, "sources": [ { - "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property.", + "$comment": "TODO: Sources control the paths for source and target content. For more details see https://aka.ms/template-json-reference#symbols#source-definition. If source definition is not required, remove the property.", "condition": "false", "source": "./source-files", "target": "./target" @@ -38,7 +38,7 @@ ], "constraints": { "SampleConstraint": { - "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property.", + "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://aka.ms/template-json-reference#symbols#template-constraints. If constraints are not required, remove the property.", "type": "os", "args": [ "Linux", "OSX", "Windows" ] } @@ -52,7 +52,7 @@ ], "postActions": [ { - "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property.", + "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://aka.ms/template-json-post-actions. If post actions are not required, remove the property.", "actionId": "84C0DA21-51C8-4541-9940-6CA19AF04EE6", "condition": "false", "id": "sample-post-action", diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.cs.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.cs.json index 571cf3fe3fb..dfc74ac6792 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.cs.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.cs.json @@ -3,5 +3,5 @@ "name": "Template Package", "description": "A project for a template package containing .NET templates.", "postActions/instructions/description": "Manual actions required", - "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.de.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.de.json index 571cf3fe3fb..dfc74ac6792 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.de.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.de.json @@ -3,5 +3,5 @@ "name": "Template Package", "description": "A project for a template package containing .NET templates.", "postActions/instructions/description": "Manual actions required", - "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.en.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.en.json index 571cf3fe3fb..dfc74ac6792 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.en.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.en.json @@ -3,5 +3,5 @@ "name": "Template Package", "description": "A project for a template package containing .NET templates.", "postActions/instructions/description": "Manual actions required", - "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.es.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.es.json index 571cf3fe3fb..dfc74ac6792 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.es.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.es.json @@ -3,5 +3,5 @@ "name": "Template Package", "description": "A project for a template package containing .NET templates.", "postActions/instructions/description": "Manual actions required", - "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.fr.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.fr.json index 571cf3fe3fb..dfc74ac6792 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.fr.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.fr.json @@ -3,5 +3,5 @@ "name": "Template Package", "description": "A project for a template package containing .NET templates.", "postActions/instructions/description": "Manual actions required", - "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.it.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.it.json index 571cf3fe3fb..dfc74ac6792 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.it.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.it.json @@ -3,5 +3,5 @@ "name": "Template Package", "description": "A project for a template package containing .NET templates.", "postActions/instructions/description": "Manual actions required", - "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ja.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ja.json index 571cf3fe3fb..dfc74ac6792 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ja.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ja.json @@ -3,5 +3,5 @@ "name": "Template Package", "description": "A project for a template package containing .NET templates.", "postActions/instructions/description": "Manual actions required", - "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ko.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ko.json index 571cf3fe3fb..dfc74ac6792 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ko.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ko.json @@ -3,5 +3,5 @@ "name": "Template Package", "description": "A project for a template package containing .NET templates.", "postActions/instructions/description": "Manual actions required", - "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pl.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pl.json index 571cf3fe3fb..dfc74ac6792 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pl.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pl.json @@ -3,5 +3,5 @@ "name": "Template Package", "description": "A project for a template package containing .NET templates.", "postActions/instructions/description": "Manual actions required", - "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pt-BR.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pt-BR.json index 571cf3fe3fb..dfc74ac6792 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pt-BR.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.pt-BR.json @@ -3,5 +3,5 @@ "name": "Template Package", "description": "A project for a template package containing .NET templates.", "postActions/instructions/description": "Manual actions required", - "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ru.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ru.json index 571cf3fe3fb..dfc74ac6792 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ru.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.ru.json @@ -3,5 +3,5 @@ "name": "Template Package", "description": "A project for a template package containing .NET templates.", "postActions/instructions/description": "Manual actions required", - "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.tr.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.tr.json index 571cf3fe3fb..dfc74ac6792 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.tr.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.tr.json @@ -3,5 +3,5 @@ "name": "Template Package", "description": "A project for a template package containing .NET templates.", "postActions/instructions/description": "Manual actions required", - "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hans.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hans.json index 571cf3fe3fb..dfc74ac6792 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hans.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hans.json @@ -3,5 +3,5 @@ "name": "Template Package", "description": "A project for a template package containing .NET templates.", "postActions/instructions/description": "Manual actions required", - "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hant.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hant.json index 571cf3fe3fb..dfc74ac6792 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hant.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/localize/templatestrings.zh-Hant.json @@ -3,5 +3,5 @@ "name": "Template Package", "description": "A project for a template package containing .NET templates.", "postActions/instructions/description": "Manual actions required", - "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "postActions/instructions/manualInstructions/default/text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } \ No newline at end of file diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json index 8ffba029a53..d4c10ba06fb 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/.template.config/template.json @@ -33,7 +33,7 @@ "description": "Manual actions required", "manualInstructions": [ { - "text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder." + "text": "Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md." } ], "actionId": "AC1156F7-BB77-4DB8-B28F-24EEBCCA1E5C", diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj index 52bf0c73a6a..33ab83a17a4 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj @@ -1,34 +1,39 @@ - - - Template - 1.0 - New.Template.Package - TODO: fill the package name here - Me - TODO: fill the package description here - dotnet-new;templates - net7.0 - true - false - content - $(NoWarn);NU5128 - true - - - - false - + + + + New.Template.Package + 1.0 + TODO: fill the package name here + TODO: fill the author name or organization here + TODO: fill the package description here + TODO: fill the tags here + TODO: include a link to an associated project, repository, or company website - - - + + Template + net7.0 + true + false + content + $(NoWarn);NU5128 + true + - - - - - + + + false + + + + + + + + + + + diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/README.md b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/README.md new file mode 100644 index 00000000000..93d46c8c99b --- /dev/null +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/README.md @@ -0,0 +1,2 @@ + diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json index cfd77f26d51..749747d8b53 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json @@ -1,6 +1,6 @@ { "$schema": "http://json.schemastore.org/template", - "$comment": "See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", + "$comment": "See https://aka.ms/template-json-reference for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", "author": "TODO: fill author name here.", "classifications": [ "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." @@ -15,12 +15,12 @@ "language": "C#", "type": "project" }, - "$comment_sourceName": "TODO: Source name should follow these rules: https://github.com/dotnet/templating/wiki/Naming-and-default-value-forms. Source name may be removed if replacement for name is not required.", + "$comment_sourceName": "TODO: Source name should follow these rules: https://aka.ms/template-json-source-name. Source name may be removed if replacement for name is not required.", "sourceName": "New.Template.1", "preferNameDirectory": true, "symbols": { "ExampleParameter": { - "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://github.com/dotnet/templating/wiki/Reference-for-template.json#symbols.", + "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://aka.ms/template-json-reference#symbols.", "type": "parameter", "datatype": "string", "defaultValue": "example", @@ -30,7 +30,7 @@ }, "sources": [ { - "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property.", + "$comment": "TODO: Sources control the paths for source and target content. For more details see https://aka.ms/template-json-reference#symbols#source-definition. If source definition is not required, remove the property.", "condition": "false", "source": "./source-files", "target": "./target" @@ -38,7 +38,7 @@ ], "constraints": { "SampleConstraint": { - "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property.", + "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://aka.ms/template-json-reference#symbols#template-constraints. If constraints are not required, remove the property.", "type": "os", "args": [ "Linux", "OSX", "Windows" ] } @@ -52,7 +52,7 @@ ], "postActions": [ { - "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property.", + "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://aka.ms/template-json-post-actions. If post actions are not required, remove the property.", "actionId": "84C0DA21-51C8-4541-9940-6CA19AF04EE6", "condition": "false", "id": "sample-post-action", diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/template.json/.template.config/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/template.json/.template.config/template.json index cfd77f26d51..749747d8b53 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/template.json/.template.config/template.json +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/template.json/.template.config/template.json @@ -1,6 +1,6 @@ { "$schema": "http://json.schemastore.org/template", - "$comment": "See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", + "$comment": "See https://aka.ms/template-json-reference for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", "author": "TODO: fill author name here.", "classifications": [ "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." @@ -15,12 +15,12 @@ "language": "C#", "type": "project" }, - "$comment_sourceName": "TODO: Source name should follow these rules: https://github.com/dotnet/templating/wiki/Naming-and-default-value-forms. Source name may be removed if replacement for name is not required.", + "$comment_sourceName": "TODO: Source name should follow these rules: https://aka.ms/template-json-source-name. Source name may be removed if replacement for name is not required.", "sourceName": "New.Template.1", "preferNameDirectory": true, "symbols": { "ExampleParameter": { - "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://github.com/dotnet/templating/wiki/Reference-for-template.json#symbols.", + "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://aka.ms/template-json-reference#symbols.", "type": "parameter", "datatype": "string", "defaultValue": "example", @@ -30,7 +30,7 @@ }, "sources": [ { - "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property.", + "$comment": "TODO: Sources control the paths for source and target content. For more details see https://aka.ms/template-json-reference#symbols#source-definition. If source definition is not required, remove the property.", "condition": "false", "source": "./source-files", "target": "./target" @@ -38,7 +38,7 @@ ], "constraints": { "SampleConstraint": { - "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property.", + "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://aka.ms/template-json-reference#symbols#template-constraints. If constraints are not required, remove the property.", "type": "os", "args": [ "Linux", "OSX", "Windows" ] } @@ -52,7 +52,7 @@ ], "postActions": [ { - "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property.", + "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://aka.ms/template-json-post-actions. If post actions are not required, remove the property.", "actionId": "84C0DA21-51C8-4541-9940-6CA19AF04EE6", "condition": "false", "id": "sample-post-action", diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json index cfd77f26d51..749747d8b53 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json @@ -1,6 +1,6 @@ { "$schema": "http://json.schemastore.org/template", - "$comment": "See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", + "$comment": "See https://aka.ms/template-json-reference for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", "author": "TODO: fill author name here.", "classifications": [ "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." @@ -15,12 +15,12 @@ "language": "C#", "type": "project" }, - "$comment_sourceName": "TODO: Source name should follow these rules: https://github.com/dotnet/templating/wiki/Naming-and-default-value-forms. Source name may be removed if replacement for name is not required.", + "$comment_sourceName": "TODO: Source name should follow these rules: https://aka.ms/template-json-source-name. Source name may be removed if replacement for name is not required.", "sourceName": "New.Template.1", "preferNameDirectory": true, "symbols": { "ExampleParameter": { - "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://github.com/dotnet/templating/wiki/Reference-for-template.json#symbols.", + "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://aka.ms/template-json-reference#symbols.", "type": "parameter", "datatype": "string", "defaultValue": "example", @@ -30,7 +30,7 @@ }, "sources": [ { - "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property.", + "$comment": "TODO: Sources control the paths for source and target content. For more details see https://aka.ms/template-json-reference#symbols#source-definition. If source definition is not required, remove the property.", "condition": "false", "source": "./source-files", "target": "./target" @@ -38,7 +38,7 @@ ], "constraints": { "SampleConstraint": { - "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property.", + "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://aka.ms/template-json-reference#symbols#template-constraints. If constraints are not required, remove the property.", "type": "os", "args": [ "Linux", "OSX", "Windows" ] } @@ -52,7 +52,7 @@ ], "postActions": [ { - "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property.", + "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://aka.ms/template-json-post-actions. If post actions are not required, remove the property.", "actionId": "84C0DA21-51C8-4541-9940-6CA19AF04EE6", "condition": "false", "id": "sample-post-action", diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json index d291983f13a..50366456186 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json @@ -1,6 +1,6 @@ { "$schema": "http://json.schemastore.org/template", - "$comment": "See https://github.com/dotnet/templating/wiki/Reference-for-template.json for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", + "$comment": "See https://aka.ms/template-json-reference for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", "author": "TODO: fill author name here.", "classifications": [ "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." @@ -15,12 +15,12 @@ "language": "C#", "type": "project" }, - "$comment_sourceName": "TODO: Source name should follow these rules: https://github.com/dotnet/templating/wiki/Naming-and-default-value-forms. Source name may be removed if replacement for name is not required.", + "$comment_sourceName": "TODO: Source name should follow these rules: https://aka.ms/template-json-source-name. Source name may be removed if replacement for name is not required.", "sourceName": "New.Template.1", "preferNameDirectory": true, "symbols": { "ExampleParameter": { - "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://github.com/dotnet/templating/wiki/Reference-for-template.json#symbols.", + "$comment": "TODO: The symbols section defines variables and their values. For more details, see https://aka.ms/template-json-reference#symbols.", "type": "parameter", "datatype": "string", "defaultValue": "example", @@ -30,7 +30,7 @@ }, "sources": [ { - "$comment": "TODO: Sources control the paths for source and target content. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#source-definition. If source definition is not required, remove the property.", + "$comment": "TODO: Sources control the paths for source and target content. For more details see https://aka.ms/template-json-reference#symbols#source-definition. If source definition is not required, remove the property.", "condition": "false", "source": "./source-files", "target": "./target" @@ -38,7 +38,7 @@ ], "constraints": { "SampleConstraint": { - "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://github.com/dotnet/templating/wiki/Reference-for-template.json#template-constraints. If constraints are not required, remove the property.", + "$comment": "TODO: The template may define the constraints all of which must be met in order for the template to be used. For more details see https://aka.ms/template-json-reference#symbols#template-constraints. If constraints are not required, remove the property.", "type": "os", "args": [ "Linux", "OSX", "Windows" ] } @@ -52,7 +52,7 @@ ], "postActions": [ { - "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://github.com/dotnet/templating/wiki/Post-Action-Registry. If post actions are not required, remove the property.", + "$comment": "TODO: Enables actions to be performed after the project is created. For more details see https://aka.ms/template-json-post-actions. If post actions are not required, remove the property.", "actionId": "84C0DA21-51C8-4541-9940-6CA19AF04EE6", "condition": "false", "id": "sample-post-action", diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/README.md b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/README.md new file mode 100644 index 00000000000..e9c4c2fb059 --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/README.md @@ -0,0 +1,2 @@ + diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/templatepack.csproj b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/templatepack.csproj index e73babd33fa..86710706682 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/templatepack.csproj +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/templatepack.csproj @@ -1,32 +1,37 @@ - - - - Template - 1.0 - templatepack - TODO: fill the package name here - Me - TODO: fill the package description here - dotnet-new;templates - net7.0 - true - false - content - $(NoWarn);NU5128 - true - + - - false - + + + + templatepack + 1.0 + TODO: fill the package name here + TODO: fill the author name or organization here + TODO: fill the package description here + TODO: fill the tags here + TODO: include a link to an associated project, repository, or company website - - - + + Template + net7.0 + true + false + content + $(NoWarn);NU5128 + true + - - - - + + false + + + + + + + + + + diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/std-streams/stdout.txt b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/std-streams/stdout.txt index 4218c30e9b1..f4cbee2a6ed 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/std-streams/stdout.txt +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/std-streams/stdout.txt @@ -2,4 +2,4 @@ Processing post-creation actions... Description: Manual actions required -Manual instructions: Open *.csproj in the editor and complete the package metadata configuration. \ No newline at end of file +Manual instructions: Open *.csproj in the editor and complete the package metadata configuration. Copy the templates to 'content' folder. Fill in README.md. \ No newline at end of file diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/README.md b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/README.md new file mode 100644 index 00000000000..e9c4c2fb059 --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/README.md @@ -0,0 +1,2 @@ + diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/templatepack.csproj b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/templatepack.csproj index e73babd33fa..86710706682 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/templatepack.csproj +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/templatepack.csproj @@ -1,32 +1,37 @@ - - - - Template - 1.0 - templatepack - TODO: fill the package name here - Me - TODO: fill the package description here - dotnet-new;templates - net7.0 - true - false - content - $(NoWarn);NU5128 - true - + - - false - + + + + templatepack + 1.0 + TODO: fill the package name here + TODO: fill the author name or organization here + TODO: fill the package description here + TODO: fill the tags here + TODO: include a link to an associated project, repository, or company website - - - + + Template + net7.0 + true + false + content + $(NoWarn);NU5128 + true + - - - - + + false + + + + + + + + + + diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/README.md b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/README.md new file mode 100644 index 00000000000..e9c4c2fb059 --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/README.md @@ -0,0 +1,2 @@ + diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/templatepack.csproj b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/templatepack.csproj index 9ebb3f4bffc..2ed1e737a3d 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/templatepack.csproj +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/templatepack.csproj @@ -1,24 +1,29 @@ - - - - Template - 1.0 - templatepack - TODO: fill the package name here - Me - TODO: fill the package description here - dotnet-new;templates - net7.0 - true - false - content - $(NoWarn);NU5128 - true - + - - - - + + + + templatepack + 1.0 + TODO: fill the package name here + TODO: fill the author name or organization here + TODO: fill the package description here + TODO: fill the tags here + TODO: include a link to an associated project, repository, or company website + + + Template + net7.0 + true + false + content + $(NoWarn);NU5128 + true + + + + + + diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/MyTemplatePackage.csproj b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/MyTemplatePackage.csproj index a4906c715e2..1fc1cd7c821 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/MyTemplatePackage.csproj +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/MyTemplatePackage.csproj @@ -1,32 +1,37 @@ - - - - Template - 1.0 - MyTemplatePackage - TODO: fill the package name here - Me - TODO: fill the package description here - dotnet-new;templates - net7.0 - true - false - content - $(NoWarn);NU5128 - true - + - - false - + + + + MyTemplatePackage + 1.0 + TODO: fill the package name here + TODO: fill the author name or organization here + TODO: fill the package description here + TODO: fill the tags here + TODO: include a link to an associated project, repository, or company website - - - + + Template + net7.0 + true + false + content + $(NoWarn);NU5128 + true + - - - - + + false + + + + + + + + + + diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/README.md b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/README.md new file mode 100644 index 00000000000..e9c4c2fb059 --- /dev/null +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/README.md @@ -0,0 +1,2 @@ + From bad06a9f99cb5413e7cb8020585efffd2f5fa7f2 Mon Sep 17 00:00:00 2001 From: Vlada Shubina Date: Wed, 18 Jan 2023 10:03:52 +0100 Subject: [PATCH 7/9] updated the target framework in the template --- .../content/TemplatePackage/New.Template.Package.csproj | 2 +- .../templatepack/templatepack.csproj | 2 +- .../templatepack.CLI.verified/templatepack/templatepack.csproj | 2 +- .../templatepack/templatepack.csproj | 2 +- .../templatepack/MyTemplatePackage.csproj | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj index 33ab83a17a4..04f8107728d 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplatePackage/New.Template.Package.csproj @@ -13,7 +13,7 @@ Template - net7.0 + net8.0 true false content diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/templatepack.csproj b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/templatepack.csproj index 86710706682..a2abc888924 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/templatepack.csproj +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.Basic.verified/templatepack/templatepack.csproj @@ -13,7 +13,7 @@ Template - net7.0 + net8.0 true false content diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/templatepack.csproj b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/templatepack.csproj index 86710706682..a2abc888924 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/templatepack.csproj +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.CLI.verified/templatepack/templatepack.csproj @@ -13,7 +13,7 @@ Template - net7.0 + net8.0 true false content diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/templatepack.csproj b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/templatepack.csproj index 2ed1e737a3d..86f28914436 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/templatepack.csproj +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.NoMSBuildTasks.verified/templatepack/templatepack.csproj @@ -13,7 +13,7 @@ Template - net7.0 + net8.0 true false content diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/MyTemplatePackage.csproj b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/MyTemplatePackage.csproj index 1fc1cd7c821..56da967270e 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/MyTemplatePackage.csproj +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/templatepack.WithName.verified/templatepack/MyTemplatePackage.csproj @@ -13,7 +13,7 @@ Template - net7.0 + net8.0 true false content From 874c739549792aa5efe38e5302412d5b754ce0c0 Mon Sep 17 00:00:00 2001 From: Vlada Shubina Date: Wed, 18 Jan 2023 10:06:54 +0100 Subject: [PATCH 8/9] added link to classification in the reference, improved description in the reference. --- docs/Reference-for-template.json.md | 2 +- .../content/TemplateJson/template.json | 2 +- .../template.json/.template.config/template.json | 2 +- .../template.json/.template.config/template.json | 2 +- .../template.json/template.json | 2 +- .../template.json/.template.config/template.json | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/Reference-for-template.json.md b/docs/Reference-for-template.json.md index f9786f64751..390887bc22d 100644 --- a/docs/Reference-for-template.json.md +++ b/docs/Reference-for-template.json.md @@ -35,7 +35,7 @@ A tutorial on how to create the template package can be find [here](https://lear |---|---|---| |`identity`|A unique name for this template|yes| |`author`|The author of the template|no| -|`classifications`|Zero or more characteristics of the template which may be used in search. In this field you define the values shown as Tags in `dotnet new`|no| +|`classifications`| Zero or more characteristics of the template which are shown in the tabular output of `dotnet new list` and `dotnet new search` as "Tags". It is possible to filter the templates based on them using `--tag` option. In Visual Studio those items are shown in New Project Dialog in the available list of templates together with template name, description and language. Common classifications are: `Library`, `Test`, `Web` etc. |no| |`name`|The name for the template. This is displayed as the template name when using `dotnet new` and Visual Studio.|yes| |`groupIdentity`|The ID of the group this template belongs to. This allows multiple templates to be displayed as one, with the the decision for which one to use based on the template options. |no| |`tags`|You can use tags to improve the metadata of your project. Well-known tags are: `language` and `type`. To specify the template language, use the tag `language`. To specify the template type, use the tag `type`. Supported types are: `project`, `item`, `solution`.|no| diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json index 6954498853e..eb638e57305 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/content/TemplateJson/template.json @@ -3,7 +3,7 @@ "$comment": "See https://aka.ms/template-json-reference for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", "author": "TODO: fill author name here.", "classifications": [ - "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." + "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array. For more details, see https://aka.ms/template-json-reference#classifications." ], "name": "New Template", "description": "TODO: fill the template description here.", diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json index 749747d8b53..3759f9bbeb1 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.Basic.verified/template.json/.template.config/template.json @@ -3,7 +3,7 @@ "$comment": "See https://aka.ms/template-json-reference for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", "author": "TODO: fill author name here.", "classifications": [ - "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." + "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array. For more details, see https://aka.ms/template-json-reference#classifications." ], "name": "New Template", "description": "TODO: fill the template description here.", diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/template.json/.template.config/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/template.json/.template.config/template.json index 749747d8b53..3759f9bbeb1 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/template.json/.template.config/template.json +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.CLI.verified/template.json/.template.config/template.json @@ -3,7 +3,7 @@ "$comment": "See https://aka.ms/template-json-reference for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", "author": "TODO: fill author name here.", "classifications": [ - "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." + "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array. For more details, see https://aka.ms/template-json-reference#classifications." ], "name": "New Template", "description": "TODO: fill the template description here.", diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json index 749747d8b53..3759f9bbeb1 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.NoConfigFolder.verified/template.json/template.json @@ -3,7 +3,7 @@ "$comment": "See https://aka.ms/template-json-reference for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", "author": "TODO: fill author name here.", "classifications": [ - "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." + "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array. For more details, see https://aka.ms/template-json-reference#classifications." ], "name": "New Template", "description": "TODO: fill the template description here.", diff --git a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json index 50366456186..d4d55a312a4 100644 --- a/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json +++ b/test/Microsoft.TemplateEngine.Authoring.Templates.IntegrationTests/Snapshots/template.json.WithParams.verified/template.json/.template.config/template.json @@ -3,7 +3,7 @@ "$comment": "See https://aka.ms/template-json-reference for complete configuration description. Complete TODOs below and remove the $comment properties. It is recommended to use the JSON editor that supports schema hints to get more information about defined JSON properties and their description.", "author": "TODO: fill author name here.", "classifications": [ - "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array." + "TODO: fill classification here. Common classifications are: Library, Test, Web etc. Each classification should be a separate element of the array. For more details, see https://aka.ms/template-json-reference#classifications." ], "name": "MyTemplate", "description": "TODO: fill the template description here.", From 577271ca1b739517e12d36351d088fcab9d336d8 Mon Sep 17 00:00:00 2001 From: Vlada Shubina Date: Wed, 18 Jan 2023 10:52:10 +0100 Subject: [PATCH 9/9] excluded authoring templates from source-build --- ....TemplateEngine.Authoring.Templates.csproj | 73 ++++++++++--------- 1 file changed, 37 insertions(+), 36 deletions(-) diff --git a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/Microsoft.TemplateEngine.Authoring.Templates.csproj b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/Microsoft.TemplateEngine.Authoring.Templates.csproj index 890ec4205b9..61e9bb8b289 100644 --- a/template_feed/Microsoft.TemplateEngine.Authoring.Templates/Microsoft.TemplateEngine.Authoring.Templates.csproj +++ b/template_feed/Microsoft.TemplateEngine.Authoring.Templates/Microsoft.TemplateEngine.Authoring.Templates.csproj @@ -1,38 +1,39 @@  - - $(NETCoreTargetFramework) - False - False - False - $(ArtifactsTmpDir) - False - true - true - true - true - 2008;NU5105 - true - Microsoft.TemplateEngine.Authoring.Templates - Microsoft - The templates for useful items and projects for template authoring. - en-US - https://github.com/dotnet/templating - Template - True - - - - - content - - - - - - - - - - - + + $(NETCoreTargetFramework) + False + False + False + $(ArtifactsTmpDir) + False + true + true + true + true + 2008;NU5105 + true + Microsoft.TemplateEngine.Authoring.Templates + Microsoft + The templates for useful items and projects for template authoring. + en-US + https://github.com/dotnet/templating + Template + True + true + + + + + content + + + + + + + + + + +