diff --git a/Avalonia.Templates.csproj b/Avalonia.Templates.csproj index 546bbf6e..15b53de9 100644 --- a/Avalonia.Templates.csproj +++ b/Avalonia.Templates.csproj @@ -2,7 +2,7 @@ Template - 11.0.5 + 11.0.6 Avalonia.Templates Avalonia Templates Templates for creating Avalonia applications and libraries. diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 450264b0..c262fa6f 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -5,7 +5,7 @@ steps: displayName: 'Use .NET SDK' inputs: packageType: 'sdk' - version: 7.0.302 + version: 8.0.100 - task: DotNetCoreCLI@2 displayName: 'Pack Templates' inputs: diff --git a/readme.md b/readme.md index 9821a244..c2a92a5b 100644 --- a/readme.md +++ b/readme.md @@ -6,7 +6,7 @@ For more information about `dotnet new` templates see [here](https://blogs.msdn. ## Installing the templates -Run from a command line (`.NET 7`): +Run from a command line (`.NET 7+`): ```powershell dotnet new install Avalonia.Templates @@ -50,17 +50,17 @@ Available parameters: *Description*: The target framework for the project. -*Options*: **net6.0**, **net7.0** +*Options*: **net6.0**, **net7.0**, **net8.0** -*By default*: net6.0 +*By default*: net8.0 ``-av, --avalonia-version`` *Description*: The target version of Avalonia NuGet packages. -*Options*: **0.10.21**, **11.0.5** +*Options*: **0.10.21**, **11.0.6** -*By default*: 11.0.5 +*By default*: 11.0.6 ``-cb, --compiled-bindings`` @@ -91,17 +91,17 @@ Available parameters: *Description*: The target framework for the project. -*Options*: **net6.0**, **net7.0** +*Options*: **net6.0**, **net7.0**, **net8.0** -*By default*: net6.0 +*By default*: net8.0 ``-av, --avalonia-version`` *Description*: The target version of Avalonia NuGet packages. -*Options*: **0.10.21**, **11.0.5** +*Options*: **0.10.21**, **11.0.6** -*By default*: 11.0.5 +*By default*: 11.0.6 ``-cb, --compiled-bindings`` diff --git a/templates/csharp/app-mvvm/.template.config/template.json b/templates/csharp/app-mvvm/.template.config/template.json index 9948edcc..980286dd 100644 --- a/templates/csharp/app-mvvm/.template.config/template.json +++ b/templates/csharp/app-mvvm/.template.config/template.json @@ -27,10 +27,14 @@ { "choice": "net7.0", "description": "Target net7.0" + }, + { + "choice": "net8.0", + "description": "Target net8.0" } ], "replaces": "FrameworkParameter", - "defaultValue": "net6.0" + "defaultValue": "net8.0" }, "skipRestore": { "type": "parameter", @@ -72,16 +76,16 @@ "description": "Target 0.10.21" }, { - "choice": "11.0.5", - "description": "Target 11.0.5 (Latest stable)" + "choice": "11.0.6", + "description": "Target 11.0.6 (Latest stable)" } ], "replaces": "AvaloniaVersionTemplateParameter", - "defaultValue": "11.0.5" + "defaultValue": "11.0.6" }, "AvaloniaStableChosen": { "type": "computed", - "value": "(AvaloniaVersion == \"11.0.5\")" + "value": "(AvaloniaVersion == \"11.0.6\")" }, "UseCompiledBindings": { "type": "parameter", @@ -89,7 +93,7 @@ "datatype": "bool", "displayName": "Use compiled Bindings", "defaultValue": "true", - "isEnabled": "(AvaloniaVersion == \"11.0.5\")" + "isEnabled": "(AvaloniaVersion == \"11.0.6\")" }, "RemoveViewLocator": { "type": "parameter", diff --git a/templates/csharp/app/.template.config/template.json b/templates/csharp/app/.template.config/template.json index bd79926c..1e0ab6ff 100644 --- a/templates/csharp/app/.template.config/template.json +++ b/templates/csharp/app/.template.config/template.json @@ -27,10 +27,14 @@ { "choice": "net7.0", "description": "Target net7.0" + }, + { + "choice": "net8.0", + "description": "Target net8.0" } ], "replaces": "FrameworkParameter", - "defaultValue": "net6.0" + "defaultValue": "net8.0" }, "skipRestore": { "type": "parameter", @@ -48,16 +52,16 @@ "description": "Target 0.10.21" }, { - "choice": "11.0.5", - "description": "Target 11.0.5 (Latest stable)" + "choice": "11.0.6", + "description": "Target 11.0.6 (Latest stable)" } ], "replaces": "AvaloniaVersionTemplateParameter", - "defaultValue": "11.0.5" + "defaultValue": "11.0.6" }, "AvaloniaStableChosen": { "type": "computed", - "value": "(AvaloniaVersion == \"11.0.5\")" + "value": "(AvaloniaVersion == \"11.0.6\")" }, "UseCompiledBindings": { "type": "parameter", @@ -65,7 +69,7 @@ "datatype": "bool", "displayName": "Use compiled Bindings", "defaultValue": "true", - "isEnabled": "(AvaloniaVersion == \"11.0.5\")" + "isEnabled": "(AvaloniaVersion == \"11.0.6\")" }, "HostIdentifier": { "type": "bind", diff --git a/templates/csharp/xplat/.template.config/template.json b/templates/csharp/xplat/.template.config/template.json index e7766347..0fdbe074 100644 --- a/templates/csharp/xplat/.template.config/template.json +++ b/templates/csharp/xplat/.template.config/template.json @@ -21,12 +21,12 @@ "datatype": "choice", "choices": [ { - "choice": "net7.0", - "description": "Target net7.0" + "choice": "net8.0", + "description": "Target net8.0" } ], "replaces": "FrameworkParameter", - "defaultValue": "net7.0" + "defaultValue": "net8.0" }, "UseCompiledBindings": { "type": "parameter", diff --git a/templates/csharp/xplat/Directory.Build.props b/templates/csharp/xplat/Directory.Build.props index 28f59c38..b7d1f090 100644 --- a/templates/csharp/xplat/Directory.Build.props +++ b/templates/csharp/xplat/Directory.Build.props @@ -1,6 +1,6 @@ enable - 11.0.5 + 11.0.6 diff --git a/templates/fsharp/app-mvvm/.template.config/template.json b/templates/fsharp/app-mvvm/.template.config/template.json index bb59d7d5..c33312c4 100644 --- a/templates/fsharp/app-mvvm/.template.config/template.json +++ b/templates/fsharp/app-mvvm/.template.config/template.json @@ -27,10 +27,14 @@ { "choice": "net7.0", "description": "Target net7.0" + }, + { + "choice": "net8.0", + "description": "Target net8.0" } ], "replaces": "FrameworkParameter", - "defaultValue": "net6.0" + "defaultValue": "net8.0" }, "skipRestore": { "type": "parameter", @@ -72,16 +76,16 @@ "description": "Target 0.10.21" }, { - "choice": "11.0.5", - "description": "Target 11.0.5 (Latest stable)" + "choice": "11.0.6", + "description": "Target 11.0.6 (Latest stable)" } ], "replaces": "AvaloniaVersionTemplateParameter", - "defaultValue": "11.0.5" + "defaultValue": "11.0.6" }, "AvaloniaStableChosen": { "type": "computed", - "value": "(AvaloniaVersion == \"11.0.5\")" + "value": "(AvaloniaVersion == \"11.0.6\")" }, "UseCompiledBindings": { "type": "parameter", @@ -89,7 +93,7 @@ "datatype": "bool", "displayName": "Use compiled Bindings", "defaultValue": "true", - "isEnabled": "(AvaloniaVersion == \"11.0.5\")" + "isEnabled": "(AvaloniaVersion == \"11.0.6\")" }, "RemoveViewLocator": { "type": "parameter", diff --git a/templates/fsharp/app/.template.config/template.json b/templates/fsharp/app/.template.config/template.json index e423641d..3fbf6f57 100644 --- a/templates/fsharp/app/.template.config/template.json +++ b/templates/fsharp/app/.template.config/template.json @@ -27,10 +27,14 @@ { "choice": "net7.0", "description": "Target net7.0" + }, + { + "choice": "net8.0", + "description": "Target net8.0" } ], "replaces": "FrameworkParameter", - "defaultValue": "net6.0" + "defaultValue": "net8.0" }, "skipRestore": { "type": "parameter", @@ -48,16 +52,16 @@ "description": "Target 0.10.21" }, { - "choice": "11.0.5", - "description": "Target 11.0.5 (Latest stable)" + "choice": "11.0.6", + "description": "Target 11.0.6 (Latest stable)" } ], "replaces": "AvaloniaVersionTemplateParameter", - "defaultValue": "11.0.5" + "defaultValue": "11.0.6" }, "AvaloniaStableChosen": { "type": "computed", - "value": "(AvaloniaVersion == \"11.0.5\")" + "value": "(AvaloniaVersion == \"11.0.6\")" }, "UseCompiledBindings": { "type": "parameter", @@ -65,7 +69,7 @@ "datatype": "bool", "displayName": "Use compiled Bindings", "defaultValue": "true", - "isEnabled": "(AvaloniaVersion == \"11.0.5\")" + "isEnabled": "(AvaloniaVersion == \"11.0.6\")" }, "HostIdentifier": { "type": "bind", diff --git a/templates/fsharp/xplat/.template.config/template.json b/templates/fsharp/xplat/.template.config/template.json index fc3df43d..88605264 100644 --- a/templates/fsharp/xplat/.template.config/template.json +++ b/templates/fsharp/xplat/.template.config/template.json @@ -21,12 +21,12 @@ "datatype": "choice", "choices": [ { - "choice": "net7.0", - "description": "Target net7.0" + "choice": "net8.0", + "description": "Target net8.0" } ], "replaces": "FrameworkParameter", - "defaultValue": "net7.0" + "defaultValue": "net8.0" }, "UseCompiledBindings": { "type": "parameter", diff --git a/templates/fsharp/xplat/Directory.Build.props b/templates/fsharp/xplat/Directory.Build.props index 70b81ac9..9b65e5ec 100644 --- a/templates/fsharp/xplat/Directory.Build.props +++ b/templates/fsharp/xplat/Directory.Build.props @@ -1,5 +1,5 @@ - 11.0.5 + 11.0.6 diff --git a/tests/build-test.ps1 b/tests/build-test.ps1 index c8556aec..166801f0 100644 --- a/tests/build-test.ps1 +++ b/tests/build-test.ps1 @@ -96,16 +96,18 @@ $binlog = [IO.Path]::GetFullPath([IO.Path]::Combine($pwd, "..", "binlog", "test. Create-And-Build "avalonia.app" "AvaloniaApp" "C#" "f" "net6.0" $binlog Create-And-Build "avalonia.app" "AvaloniaApp" "C#" "f" "net7.0" $binlog +Create-And-Build "avalonia.app" "AvaloniaApp" "C#" "f" "net8.0" $binlog Create-And-Build "avalonia.app" "AvaloniaApp" "C#" "av" "0.10.21" $binlog -Create-And-Build "avalonia.app" "AvaloniaApp" "C#" "av" "11.0.5" $binlog +Create-And-Build "avalonia.app" "AvaloniaApp" "C#" "av" "11.0.6" $binlog Create-And-Build "avalonia.app" "AvaloniaApp" "C#" "cb" "true" $binlog Create-And-Build "avalonia.app" "AvaloniaApp" "C#" "cb" "false" $binlog # Build the project only twice with all item templates,once with .net6.0 tfm and once with .net7.0 tfm for C# and F# Test-Template "avalonia.mvvm" "AvaloniaMvvm" "C#" "f" "net6.0" $binlog Test-Template "avalonia.mvvm" "AvaloniaMvvm" "C#" "f" "net7.0" $binlog +Test-Template "avalonia.mvvm" "AvaloniaMvvm" "C#" "f" "net8.0" $binlog Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "C#" "av" "0.10.21" $binlog -Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "C#" "av" "11.0.5" $binlog +Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "C#" "av" "11.0.6" $binlog Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "C#" "m" "ReactiveUI" $binlog Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "C#" "m" "CommunityToolkit" $binlog Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "C#" "cb" "true" $binlog @@ -113,7 +115,7 @@ Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "C#" "cb" "false" $binlog Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "C#" "rvl" "true" $binlog Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "C#" "rvl" "false" $binlog -Create-And-Build "avalonia.xplat" "AvaloniaXplat" "C#" "f" "net7.0" $binlog +Create-And-Build "avalonia.xplat" "AvaloniaXplat" "C#" "f" "net8.0" $binlog Create-And-Build "avalonia.xplat" "AvaloniaXplat" "C#" "cb" "true" $binlog Create-And-Build "avalonia.xplat" "AvaloniaXplat" "C#" "cb" "false" $binlog Create-And-Build "avalonia.xplat" "AvaloniaXplat" "C#" "rvl" "true" $binlog @@ -121,15 +123,19 @@ Create-And-Build "avalonia.xplat" "AvaloniaXplat" "C#" "rvl" "false" $binlog Create-And-Build "avalonia.app" "AvaloniaApp" "F#" "f" "net6.0" $binlog Create-And-Build "avalonia.app" "AvaloniaApp" "F#" "f" "net7.0" $binlog +Create-And-Build "avalonia.app" "AvaloniaApp" "F#" "f" "net8.0" $binlog Create-And-Build "avalonia.app" "AvaloniaApp" "F#" "av" "0.10.21" $binlog -Create-And-Build "avalonia.app" "AvaloniaApp" "F#" "av" "11.0.5" $binlog +Create-And-Build "avalonia.app" "AvaloniaApp" "F#" "av" "11.0.6" $binlog Create-And-Build "avalonia.app" "AvaloniaApp" "F#" "cb" "true" $binlog Create-And-Build "avalonia.app" "AvaloniaApp" "F#" "cb" "false" $binlog +Remove-Item -Recurse "output/C#" + Test-Template "avalonia.mvvm" "AvaloniaMvvm" "F#" "f" "net6.0" $binlog Test-Template "avalonia.mvvm" "AvaloniaMvvm" "F#" "f" "net7.0" $binlog +Test-Template "avalonia.mvvm" "AvaloniaMvvm" "F#" "f" "net8.0" $binlog Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "F#" "av" "0.10.21" $binlog -Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "F#" "av" "11.0.5" $binlog +Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "F#" "av" "11.0.6" $binlog Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "F#" "m" "ReactiveUI" $binlog Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "F#" "m" "CommunityToolkit" $binlog Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "F#" "cb" "true" $binlog @@ -137,7 +143,7 @@ Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "F#" "cb" "false" $binlog Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "F#" "rvl" "true" $binlog Create-And-Build "avalonia.mvvm" "AvaloniaMvvm" "F#" "rvl" "false" $binlog -Create-And-Build "avalonia.xplat" "AvaloniaXplat" "F#" "f" "net7.0" $binlog +Create-And-Build "avalonia.xplat" "AvaloniaXplat" "F#" "f" "net8.0" $binlog Create-And-Build "avalonia.xplat" "AvaloniaXplat" "F#" "cb" "true" $binlog Create-And-Build "avalonia.xplat" "AvaloniaXplat" "F#" "cb" "false" $binlog Create-And-Build "avalonia.xplat" "AvaloniaXplat" "F#" "rvl" "true" $binlog