Skip to content

Commit d6c54b3

Browse files
Update dotnet version in template (#17170)
1 parent c2b1482 commit d6c54b3

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

templates/UmbracoProject/.template.config/template.json

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,15 +108,19 @@
108108
"type": "generated",
109109
"generator": "switch",
110110
"datatype": "text",
111-
"description": "Not relevant at the moment, but if we need to change the dotnet version based on the Umbraco version, we can do it here",
111+
"description": "Used to calculate the dotnet version to use, for latest we want to use dotnet 9 and for LTS we want to use dotnet 8",
112112
"replaces": "DOTNET_VERSION_FROM_TEMPLATE",
113113
"parameters": {
114114
"evaluator": "C++",
115115
"datatype": "text",
116116
"cases": [
117117
{
118-
"condition": "(true)",
118+
"condition": "(UmbracoRelease == 'Latest')",
119119
"value": "net9.0"
120+
},
121+
{
122+
"condition": "(UmbracoRelease == 'LTS')",
123+
"value": "net8.0"
120124
}
121125
]
122126
}

templates/UmbracoProject/UmbracoProject.csproj

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
<Project Sdk="Microsoft.NET.Sdk.Web">
22
<PropertyGroup>
3-
<TargetFramework>net9.0</TargetFramework>
43
<TargetFramework>DOTNET_VERSION_FROM_TEMPLATE</TargetFramework>
54
<ImplicitUsings>enable</ImplicitUsings>
65
<Nullable>enable</Nullable>

0 commit comments

Comments
 (0)