diff --git a/templates/.editorconfig b/templates/.editorconfig
new file mode 100644
index 000000000000..8e7e638d6883
--- /dev/null
+++ b/templates/.editorconfig
@@ -0,0 +1,2 @@
+# Do not inherit customized EditorConfig for template content
+root = true
diff --git a/templates/Directory.Build.props b/templates/Directory.Build.props
index c4e40e3e066a..5e5e16699f0a 100644
--- a/templates/Directory.Build.props
+++ b/templates/Directory.Build.props
@@ -1,4 +1,4 @@
-
-
+
+
diff --git a/templates/Umbraco.Templates.csproj b/templates/Umbraco.Templates.csproj
index 165e767bec10..d57b0d0d1812 100644
--- a/templates/Umbraco.Templates.csproj
+++ b/templates/Umbraco.Templates.csproj
@@ -1,66 +1,65 @@
-
- Umbraco CMS - Templates
- Contains templates for Umbraco CMS, as well as the templates for creating new packages for the Umbraco CMS.
- Template
- false
- false
- true
- true
- .
- NU5128
-
+
+ Umbraco CMS - Templates
+ Contains templates for Umbraco CMS, as well as the templates for creating new packages for the Umbraco CMS.
+ Template
+ false
+ false
+ true
+ true
+ .
+ NU5128
+
-
-
-
-
-
- UmbracoProject\Program.cs
- UmbracoProject
-
-
- UmbracoProject\Views\Partials\blocklist\%(RecursiveDir)%(Filename)%(Extension)
- UmbracoProject\Views\Partials\blocklist
-
-
- UmbracoProject\Views\Partials\grid\%(RecursiveDir)%(Filename)%(Extension)
- UmbracoProject\Views\Partials\grid
-
-
- UmbracoProject\Views\Partials\blockgrid\%(RecursiveDir)%(Filename)%(Extension)
- UmbracoProject\Views\Partials\blockgrid
-
-
- UmbracoProject\Views\_ViewImports.cshtml
- UmbracoProject\Views
-
-
- UmbracoProject\wwwroot\favicon.ico
- UmbracoProject\wwwroot
-
-
+
+
+
+
+ UmbracoProject\Program.cs
+ UmbracoProject
+
+
+ UmbracoProject\Views\Partials\blocklist\%(RecursiveDir)%(Filename)%(Extension)
+ UmbracoProject\Views\Partials\blocklist
+
+
+ UmbracoProject\Views\Partials\grid\%(RecursiveDir)%(Filename)%(Extension)
+ UmbracoProject\Views\Partials\grid
+
+
+ UmbracoProject\Views\Partials\blockgrid\%(RecursiveDir)%(Filename)%(Extension)
+ UmbracoProject\Views\Partials\blockgrid
+
+
+ UmbracoProject\Views\_ViewImports.cshtml
+ UmbracoProject\Views
+
+
+ UmbracoProject\wwwroot\favicon.ico
+ UmbracoProject\wwwroot
+
+
-
-
-
-
-
-
-
-
-
- <_TemplateJsonFiles Include="**\.template.config\template.json" Exclude="bin\**;obj\**" />
- <_TemplateJsonFiles>
- $(IntermediateOutputPath)%(RelativeDir)%(Filename)%(Extension)
-
-
-
-
-
- <_PackageFiles Include="%(_TemplateJsonFiles.DestinationFile)">
- %(_TemplateJsonFiles.RelativeDir)
-
-
-
+
+
+
+
+
+
+
+
+
+ <_TemplateJsonFiles Include="**\.template.config\template.json" Exclude="bin\**;obj\**" />
+ <_TemplateJsonFiles>
+ $(IntermediateOutputPath)%(RelativeDir)%(Filename)%(Extension)
+
+
+
+
+
+ <_PackageFiles Include="%(_TemplateJsonFiles.DestinationFile)">
+ %(_TemplateJsonFiles.RelativeDir)
+
+
+
diff --git a/templates/UmbracoPackage/.template.config/dotnetcli.host.json b/templates/UmbracoPackage/.template.config/dotnetcli.host.json
index 6473c5c643b5..6b83c15e67ae 100644
--- a/templates/UmbracoPackage/.template.config/dotnetcli.host.json
+++ b/templates/UmbracoPackage/.template.config/dotnetcli.host.json
@@ -13,6 +13,10 @@
"SkipRestore": {
"longName": "no-restore",
"shortName": ""
+ },
+ "SupportPagesAndViews": {
+ "longName": "support-pages-and-views",
+ "shortName": "s"
}
}
}
diff --git a/templates/UmbracoPackage/.template.config/ide.host.json b/templates/UmbracoPackage/.template.config/ide.host.json
index 0464cfeb1f10..6d9872c7447e 100644
--- a/templates/UmbracoPackage/.template.config/ide.host.json
+++ b/templates/UmbracoPackage/.template.config/ide.host.json
@@ -4,12 +4,17 @@
"icon": "../../icon.png",
"description": {
"id": "UmbracoPackage",
- "text": "Umbraco Package - An empty Umbraco CMS package/plugin."
+ "text": "Umbraco Package - An empty Umbraco package/plugin."
},
"symbolInfo": [
{
"id": "UmbracoVersion",
"isVisible": true
+ },
+ {
+ "id": "SupportPagesAndViews",
+ "isVisible": true,
+ "persistenceScope": "templateGroup"
}
]
}
diff --git a/templates/UmbracoPackage/.template.config/template.json b/templates/UmbracoPackage/.template.config/template.json
index 33ec0699b1c9..6124457d399a 100644
--- a/templates/UmbracoPackage/.template.config/template.json
+++ b/templates/UmbracoPackage/.template.config/template.json
@@ -9,7 +9,7 @@
"Plugin"
],
"name": "Umbraco Package",
- "description": "An empty Umbraco package/plugin project ready to get started.",
+ "description": "An empty Umbraco package/plugin.",
"groupIdentity": "Umbraco.Templates.UmbracoPackage",
"identity": "Umbraco.Templates.UmbracoPackage.CSharp",
"shortName": "umbracopackage",
@@ -51,39 +51,12 @@
"datatype": "bool",
"defaultValue": "false"
},
- "Namespace": {
- "type": "derived",
- "valueSource": "name",
- "valueTransform": "safe_namespace",
- "fileRename": "UmbracoPackage",
- "replaces": "UmbracoPackage"
- },
- "MsBuildName": {
- "type": "generated",
- "generator": "regex",
- "dataType": "string",
- "parameters": {
- "source": "name",
- "steps": [
- {
- "regex": "\\s",
- "replacement": ""
- },
- {
- "regex": "\\.",
- "replacement": ""
- },
- {
- "regex": "-",
- "replacement": ""
- },
- {
- "regex": "^[^a-zA-Z_]+",
- "replacement": ""
- }
- ]
- },
- "replaces": "UmbracoPackageMsBuild"
+ "SupportPagesAndViews": {
+ "type": "parameter",
+ "datatype": "bool",
+ "defaultValue": "false",
+ "displayName": "Support pages and views",
+ "description": "Whether to support adding traditional Razor pages and Views to this library."
}
},
"primaryOutputs": [
diff --git a/templates/UmbracoPackage/App_Plugins/UmbracoPackage/package.manifest b/templates/UmbracoPackage/App_Plugins/UmbracoPackage/package.manifest
deleted file mode 100644
index db8d6385fc29..000000000000
--- a/templates/UmbracoPackage/App_Plugins/UmbracoPackage/package.manifest
+++ /dev/null
@@ -1,5 +0,0 @@
-{
- "id": "UmbracoPackage",
- "name": "UmbracoPackage",
- "allowPackageTelemetry": true
-}
diff --git a/templates/UmbracoPackage/UmbracoPackage.csproj b/templates/UmbracoPackage/UmbracoPackage.csproj
index 268611b9aeba..0bec6e45516b 100644
--- a/templates/UmbracoPackage/UmbracoPackage.csproj
+++ b/templates/UmbracoPackage/UmbracoPackage.csproj
@@ -1,22 +1,27 @@
-
-
- net8.0
- .
- UmbracoPackage
- UmbracoPackage
- UmbracoPackage
- ...
- umbraco plugin package
- UmbracoPackage
-
+
+
+ net8.0
+ enable
+ enable
+ true
+ UmbracoPackage
+ App_Plugins/UmbracoPackage
+
-
-
-
-
+
+ UmbracoPackage
+ UmbracoPackage
+ UmbracoPackage
+ ...
+ umbraco plugin package
+
-
-
-
-
+
+
+
+
+
+
+
+
diff --git a/templates/UmbracoPackage/buildTransitive/UmbracoPackage.targets b/templates/UmbracoPackage/buildTransitive/UmbracoPackage.targets
deleted file mode 100644
index 4c376ac97b36..000000000000
--- a/templates/UmbracoPackage/buildTransitive/UmbracoPackage.targets
+++ /dev/null
@@ -1,21 +0,0 @@
-
-
- $(MSBuildThisFileDirectory)..\App_Plugins\UmbracoPackage\**\*.*
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/templates/UmbracoPackage/wwwroot/package.manifest b/templates/UmbracoPackage/wwwroot/package.manifest
new file mode 100644
index 000000000000..519d15d145bb
--- /dev/null
+++ b/templates/UmbracoPackage/wwwroot/package.manifest
@@ -0,0 +1,5 @@
+{
+ "id": "UmbracoPackage",
+ "name": "UmbracoPackage",
+ "allowPackageTelemetry": true
+}
diff --git a/templates/UmbracoPackageRcl/.template.config/dotnetcli.host.json b/templates/UmbracoPackageRcl/.template.config/dotnetcli.host.json
deleted file mode 100644
index 9a960b348e93..000000000000
--- a/templates/UmbracoPackageRcl/.template.config/dotnetcli.host.json
+++ /dev/null
@@ -1,22 +0,0 @@
-{
- "$schema": "https://json.schemastore.org/dotnetcli.host.json",
- "symbolInfo": {
- "Framework": {
- "longName": "Framework",
- "shortName": "F",
- "isHidden": true
- },
- "UmbracoVersion": {
- "longName": "version",
- "shortName": ""
- },
- "SkipRestore": {
- "longName": "no-restore",
- "shortName": ""
- },
- "SupportPagesAndViews": {
- "longName": "support-pages-and-views",
- "shortName": "s"
- }
- }
-}
diff --git a/templates/UmbracoPackageRcl/.template.config/ide.host.json b/templates/UmbracoPackageRcl/.template.config/ide.host.json
deleted file mode 100644
index 8e630f1e99f8..000000000000
--- a/templates/UmbracoPackageRcl/.template.config/ide.host.json
+++ /dev/null
@@ -1,20 +0,0 @@
-{
- "$schema": "https://json.schemastore.org/ide.host.json",
- "order": 0,
- "icon": "../../icon.png",
- "description": {
- "id": "UmbracoPackageRcl",
- "text": "Umbraco Package RCL - An empty Umbraco package/plugin (Razor Class Library)."
- },
- "symbolInfo": [
- {
- "id": "UmbracoVersion",
- "isVisible": true
- },
- {
- "id": "SupportPagesAndViews",
- "isVisible": true,
- "persistenceScope": "templateGroup"
- }
- ]
-}
diff --git a/templates/UmbracoPackageRcl/.template.config/template.json b/templates/UmbracoPackageRcl/.template.config/template.json
deleted file mode 100644
index c887e8902cfa..000000000000
--- a/templates/UmbracoPackageRcl/.template.config/template.json
+++ /dev/null
@@ -1,82 +0,0 @@
-{
- "$schema": "https://json.schemastore.org/template.json",
- "author": "Umbraco HQ",
- "classifications": [
- "Web",
- "CMS",
- "Umbraco",
- "Package",
- "Plugin",
- "Razor Class Library"
- ],
- "name": "Umbraco Package RCL",
- "description": "An empty Umbraco package/plugin (Razor Class Library).",
- "groupIdentity": "Umbraco.Templates.UmbracoPackageRcl",
- "identity": "Umbraco.Templates.UmbracoPackageRcl.CSharp",
- "shortName": "umbracopackage-rcl",
- "tags": {
- "language": "C#",
- "type": "project"
- },
- "sourceName": "UmbracoPackage",
- "defaultName": "UmbracoPackage1",
- "preferNameDirectory": true,
- "symbols": {
- "Framework": {
- "displayName": "Framework",
- "description": "The target framework for the project.",
- "type": "parameter",
- "datatype": "choice",
- "choices": [
- {
- "displayName": ".NET 8.0",
- "description": "Target net8.0",
- "choice": "net8.0"
- }
- ],
- "defaultValue": "net8.0",
- "replaces": "net8.0"
- },
- "UmbracoVersion": {
- "displayName": "Umbraco version",
- "description": "The version of Umbraco.Cms to add as PackageReference.",
- "type": "parameter",
- "datatype": "string",
- "defaultValue": "*",
- "replaces": "UMBRACO_VERSION_FROM_TEMPLATE"
- },
- "SkipRestore": {
- "displayName": "Skip restore",
- "description": "If specified, skips the automatic restore of the project on create.",
- "type": "parameter",
- "datatype": "bool",
- "defaultValue": "false"
- },
- "SupportPagesAndViews": {
- "type": "parameter",
- "datatype": "bool",
- "defaultValue": "false",
- "displayName": "Support pages and views",
- "description": "Whether to support adding traditional Razor pages and Views to this library."
- }
- },
- "primaryOutputs": [
- {
- "path": "UmbracoPackage.csproj"
- }
- ],
- "postActions": [
- {
- "id": "restore",
- "condition": "(!SkipRestore)",
- "description": "Restore NuGet packages required by this project.",
- "manualInstructions": [
- {
- "text": "Run 'dotnet restore'"
- }
- ],
- "actionId": "210D431B-A78B-4D2F-B762-4ED3E3EA9025",
- "continueOnError": true
- }
- ]
-}
diff --git a/templates/UmbracoPackageRcl/UmbracoPackage.csproj b/templates/UmbracoPackageRcl/UmbracoPackage.csproj
deleted file mode 100644
index 1cbdd209e505..000000000000
--- a/templates/UmbracoPackageRcl/UmbracoPackage.csproj
+++ /dev/null
@@ -1,27 +0,0 @@
-
-
- net8.0
- enable
- enable
- true
- UmbracoPackage
- App_Plugins/UmbracoPackage
-
-
-
- UmbracoPackage
- UmbracoPackage
- UmbracoPackage
- ...
- umbraco plugin package
-
-
-
-
-
-
-
-
-
-
-
diff --git a/templates/UmbracoPackageRcl/wwwroot/package.manifest b/templates/UmbracoPackageRcl/wwwroot/package.manifest
deleted file mode 100644
index db8d6385fc29..000000000000
--- a/templates/UmbracoPackageRcl/wwwroot/package.manifest
+++ /dev/null
@@ -1,5 +0,0 @@
-{
- "id": "UmbracoPackage",
- "name": "UmbracoPackage",
- "allowPackageTelemetry": true
-}
diff --git a/templates/UmbracoProject/.template.config/dotnetcli.host.json b/templates/UmbracoProject/.template.config/dotnetcli.host.json
index dfd6f80184b7..297515fc52a7 100644
--- a/templates/UmbracoProject/.template.config/dotnetcli.host.json
+++ b/templates/UmbracoProject/.template.config/dotnetcli.host.json
@@ -53,11 +53,6 @@
"NoNodesViewPath": {
"longName": "no-nodes-view-path",
"shortName": ""
- },
- "PackageProjectName": {
- "longName": "PackageTestSiteName",
- "shortName": "p",
- "isHidden": true
}
},
"usageExamples": [
diff --git a/templates/UmbracoProject/.template.config/template.json b/templates/UmbracoProject/.template.config/template.json
index b17352476ea5..91994a7fdf0c 100644
--- a/templates/UmbracoProject/.template.config/template.json
+++ b/templates/UmbracoProject/.template.config/template.json
@@ -236,14 +236,6 @@
"type": "computed",
"value": "(NoNodesViewPath != '')"
},
- "PackageProjectName": {
- "displayName": "Umbraco package project name",
- "description": "The name of the package project this should be a test site for.",
- "type": "parameter",
- "datatype": "string",
- "defaultValue": "",
- "replaces": "PACKAGE_PROJECT_NAME_FROM_TEMPLATE"
- },
"Namespace": {
"type": "derived",
"valueSource": "name",
diff --git a/templates/UmbracoProject/Properties/launchSettings.json b/templates/UmbracoProject/Properties/launchSettings.json
index 97fdc9f7f517..7b80bdaa38a9 100644
--- a/templates/UmbracoProject/Properties/launchSettings.json
+++ b/templates/UmbracoProject/Properties/launchSettings.json
@@ -23,7 +23,7 @@
"applicationUrl": "https://localhost:HTTPS_PORT_FROM_TEMPLATE;http://localhost:HTTP_PORT_FROM_TEMPLATE",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
- }
+ }
}
}
}
diff --git a/templates/UmbracoProject/UmbracoProject.csproj b/templates/UmbracoProject/UmbracoProject.csproj
index 4e513640790f..4d393153b347 100644
--- a/templates/UmbracoProject/UmbracoProject.csproj
+++ b/templates/UmbracoProject/UmbracoProject.csproj
@@ -1,34 +1,29 @@
-
- net8.0
- enable
- enable
- Umbraco.Cms.Web.UI
-
+
+ net8.0
+ enable
+ enable
+ Umbraco.Cms.Web.UI
+
-
-
-
+
+
+
-
-
-
-
-
+
+
+
+
+
-
-
- true
-
+
+
+ true
+
-
-
- false
- false
-
-
-
-
-
-
+
+
+ false
+ false
+