From 3eb85079852d4f9c707e922dff1e7a1908be8911 Mon Sep 17 00:00:00 2001 From: Florian Rappl Date: Wed, 12 Nov 2025 13:48:03 +0100 Subject: [PATCH 1/3] Updated to target .NET 10 as well --- .github/workflows/ci.yml | 2 ++ docs/GettingStarted/Console-App.md | 4 ++-- docs/Using/Package-Building.md | 8 ++++---- src/ElectronNET.API/ElectronNET.API.csproj | 2 +- src/ElectronNET.AspNet/ElectronNET.AspNet.csproj | 8 +++++++- src/ElectronNET/ElectronNET.csproj | 2 +- 6 files changed, 17 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a0e7cfb..093dc5f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,6 +19,7 @@ jobs: dotnet-version: | 6.0.x 8.0.x + 10.0.x - name: Build run: ./build.sh @@ -35,6 +36,7 @@ jobs: dotnet-version: | 6.0.x 8.0.x + 10.0.x - name: Build run: | diff --git a/docs/GettingStarted/Console-App.md b/docs/GettingStarted/Console-App.md index f9efe16..c848373 100644 --- a/docs/GettingStarted/Console-App.md +++ b/docs/GettingStarted/Console-App.md @@ -49,12 +49,12 @@ Add the Electron.NET configuration to your `.csproj` file: ```xml Exe - net8.0 + net10.0 win-x64 - + ``` diff --git a/docs/Using/Package-Building.md b/docs/Using/Package-Building.md index 110c850..2838595 100644 --- a/docs/Using/Package-Building.md +++ b/docs/Using/Package-Building.md @@ -28,7 +28,7 @@ Add publish profiles to `Properties/PublishProfiles/`: Any CPU publish\$(Configuration)\$(TargetFramework)\$(RuntimeIdentifier)\ FileSystem - net8.0 + net10.0 win-x64 true false @@ -48,7 +48,7 @@ Add publish profiles to `Properties/PublishProfiles/`: Any CPU publish\$(Configuration)\$(TargetFramework)\$(RuntimeIdentifier)\ FileSystem - net8.0 + net10.0 linux-x64 true false @@ -68,7 +68,7 @@ Add publish profiles to `Properties/PublishProfiles/`: Any CPU publish\$(Configuration)\$(TargetFramework)\$(RuntimeIdentifier)\ FileSystem - net8.0 + net10.0 win-x64 false false @@ -89,7 +89,7 @@ Add publish profiles to `Properties/PublishProfiles/`: Any CPU publish\$(Configuration)\$(TargetFramework)\$(RuntimeIdentifier)\ FileSystem - net8.0 + net10.0 linux-x64 false false diff --git a/src/ElectronNET.API/ElectronNET.API.csproj b/src/ElectronNET.API/ElectronNET.API.csproj index 3043599..3a50011 100644 --- a/src/ElectronNET.API/ElectronNET.API.csproj +++ b/src/ElectronNET.API/ElectronNET.API.csproj @@ -3,7 +3,7 @@ - net6.0;net8.0 + net6.0;net8.0;net10.0 ..\..\artifacts $(PackageNamePrefix).API $(PackageId) diff --git a/src/ElectronNET.AspNet/ElectronNET.AspNet.csproj b/src/ElectronNET.AspNet/ElectronNET.AspNet.csproj index 17cdd14..1c098ca 100644 --- a/src/ElectronNET.AspNet/ElectronNET.AspNet.csproj +++ b/src/ElectronNET.AspNet/ElectronNET.AspNet.csproj @@ -3,7 +3,7 @@ - net6.0;net8.0 + net6.0;net8.0;net10.0 ..\..\artifacts $(PackageNamePrefix).AspNet $(PackageId) @@ -20,12 +20,18 @@ 1701;1702;4014;CS4014;CA1416;CS1591 + + 1701;1702;4014;CS4014;CA1416;CS1591 + 1701;1702;4014;CS4014;CA1416;CS1591 1701;1702;4014;CS4014;CA1416;CS1591 + + 1701;1702;4014;CS4014;CA1416;CS1591 + diff --git a/src/ElectronNET/ElectronNET.csproj b/src/ElectronNET/ElectronNET.csproj index 9a7e9a2..48abf45 100644 --- a/src/ElectronNET/ElectronNET.csproj +++ b/src/ElectronNET/ElectronNET.csproj @@ -3,7 +3,7 @@ - net6.0;net8.0 + net6.0;net8.0;net10.0 ..\..\artifacts $(PackageNamePrefix) $(PackageId) From 0188051d6cae44773b2ed215ea1d20f1f4f1deca Mon Sep 17 00:00:00 2001 From: Florian Rappl Date: Wed, 12 Nov 2025 14:21:11 +0100 Subject: [PATCH 2/3] Updated NUKE and integrated tests in CI/CD --- .nuke/build.schema.json | 161 ++++++++++---------- Changelog.md | 1 + LICENSE | 2 +- global.json | 2 +- nuke/Build.cs | 23 ++- nuke/_build.csproj | 4 +- src/ElectronNET/build/ElectronNET.Build.dll | Bin 8192 -> 8192 bytes src/common.props | 2 +- 8 files changed, 98 insertions(+), 97 deletions(-) diff --git a/.nuke/build.schema.json b/.nuke/build.schema.json index 466bf0f..ee329a6 100644 --- a/.nuke/build.schema.json +++ b/.nuke/build.schema.json @@ -1,23 +1,54 @@ { "$schema": "http://json-schema.org/draft-04/schema#", - "$ref": "#/definitions/build", - "title": "Build Schema", "definitions": { - "build": { - "type": "object", + "Host": { + "type": "string", + "enum": [ + "AppVeyor", + "AzurePipelines", + "Bamboo", + "Bitbucket", + "Bitrise", + "GitHubActions", + "GitLab", + "Jenkins", + "Rider", + "SpaceAutomation", + "TeamCity", + "Terminal", + "TravisCI", + "VisualStudio", + "VSCode" + ] + }, + "ExecutableTarget": { + "type": "string", + "enum": [ + "Clean", + "Compile", + "Default", + "Package", + "PrePublish", + "Publish", + "PublishPackages", + "PublishPreRelease", + "PublishRelease", + "Restore", + "RunUnitTests" + ] + }, + "Verbosity": { + "type": "string", + "description": "", + "enum": [ + "Verbose", + "Normal", + "Minimal", + "Quiet" + ] + }, + "NukeBuild": { "properties": { - "CommonPropsFilePath": { - "type": "string", - "description": "common.props file path - to determine the configured version" - }, - "Configuration": { - "type": "string", - "description": "Configuration to build - Default is 'Debug' (local) or 'Release' (server)", - "enum": [ - "Debug", - "Release" - ] - }, "Continue": { "type": "boolean", "description": "Indicates to continue a previously failed build attempt" @@ -27,25 +58,8 @@ "description": "Shows the help text for this build assembly" }, "Host": { - "type": "string", "description": "Host for execution. Default is 'automatic'", - "enum": [ - "AppVeyor", - "AzurePipelines", - "Bamboo", - "Bitbucket", - "Bitrise", - "GitHubActions", - "GitLab", - "Jenkins", - "Rider", - "SpaceAutomation", - "TeamCity", - "Terminal", - "TravisCI", - "VisualStudio", - "VSCode" - ] + "$ref": "#/definitions/Host" }, "NoLogo": { "type": "boolean", @@ -66,10 +80,6 @@ "type": "string" } }, - "ReleaseNotesFilePath": { - "type": "string", - "description": "ReleaseNotesFilePath - To determine the lates changelog version" - }, "Root": { "type": "string", "description": "Root directory during build execution" @@ -78,59 +88,50 @@ "type": "array", "description": "List of targets to be skipped. Empty list skips all dependencies", "items": { - "type": "string", - "enum": [ - "Clean", - "Compile", - "CreatePackages", - "Default", - "Package", - "PrePublish", - "Publish", - "PublishPackages", - "PublishPreRelease", - "PublishRelease", - "Restore", - "RunUnitTests" - ] + "$ref": "#/definitions/ExecutableTarget" } }, - "Solution": { - "type": "string", - "description": "Path to a solution file that is automatically loaded" - }, "Target": { "type": "array", "description": "List of targets to be invoked. Default is '{default_target}'", "items": { - "type": "string", - "enum": [ - "Clean", - "Compile", - "CreatePackages", - "Default", - "Package", - "PrePublish", - "Publish", - "PublishPackages", - "PublishPreRelease", - "PublishRelease", - "Restore", - "RunUnitTests" - ] + "$ref": "#/definitions/ExecutableTarget" } }, "Verbosity": { - "type": "string", "description": "Logging verbosity during build execution. Default is 'Normal'", - "enum": [ - "Minimal", - "Normal", - "Quiet", - "Verbose" - ] + "$ref": "#/definitions/Verbosity" } } } - } + }, + "allOf": [ + { + "properties": { + "CommonPropsFilePath": { + "type": "string", + "description": "common.props file path - to determine the configured version" + }, + "Configuration": { + "type": "string", + "description": "Configuration to build - Default is 'Debug' (local) or 'Release' (server)", + "enum": [ + "Debug", + "Release" + ] + }, + "ReleaseNotesFilePath": { + "type": "string", + "description": "ReleaseNotesFilePath - To determine the lates changelog version" + }, + "Solution": { + "type": "string", + "description": "Path to a solution file that is automatically loaded" + } + } + }, + { + "$ref": "#/definitions/NukeBuild" + } + ] } diff --git a/Changelog.md b/Changelog.md index 2062e42..ae37cc9 100644 --- a/Changelog.md +++ b/Changelog.md @@ -12,6 +12,7 @@ - Added option to provide floating point value as aspect ratios with `SetAspectRatio` (#793) - Added `TitleBarOverlay` property to `BrowserWindowOptions` (#909) - Added `RoundedCorners` property to `BrowserWindowOptions` +- Added .NET 10 as an explicit target # 0.0.18 diff --git a/LICENSE b/LICENSE index 5d83f95..9e71947 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2017-2024 Gregor Biswanger, Robert Mühsig +Copyright (c) 2017-2025 Gregor Biswanger, Robert Mühsig, Florian Rappl Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/global.json b/global.json index ceda25e..ef313ab 100644 --- a/global.json +++ b/global.json @@ -1,6 +1,6 @@ { "sdk": { - "version": "8.0.305", + "version": "10.0.100", "rollForward": "feature", "allowPrerelease": false } diff --git a/nuke/Build.cs b/nuke/Build.cs index 8fe3b44..e4fe84e 100644 --- a/nuke/Build.cs +++ b/nuke/Build.cs @@ -3,6 +3,7 @@ using Nuke.Common; using Nuke.Common.CI.GitHubActions; using Nuke.Common.IO; using Nuke.Common.ProjectModel; +using Nuke.Common.Tooling; using Nuke.Common.Tools.DotNet; using Nuke.Common.Tools.GitHub; using Nuke.Common.Tools.NuGet; @@ -15,7 +16,6 @@ using System.Collections.Generic; using System.IO; using System.Linq; -using static Nuke.Common.IO.FileSystemTasks; using static Nuke.Common.IO.PathConstruction; using static Nuke.Common.Tools.DotNet.DotNetTasks; // ReSharper disable ArrangeThisQualifier @@ -116,7 +116,7 @@ class Build : NukeBuild Target Restore => _ => _ .Executes(() => { - DotNetRestore(s => s.SetProjectFile(Solution.Path)); + DotNetRestore(s => s.SetProjectFile(Solution)); }); Target Compile => _ => _ @@ -124,7 +124,7 @@ class Build : NukeBuild .Executes(() => { DotNetBuild(s => s - .SetProjectFile(Solution.Path) + .SetProjectFile(Solution) .SetConfiguration(Configuration) .SetProperty("GeneratePackageOnBuild", "True") .SetProperty("VersionPostFix", VersionPostFix ?? string.Empty)); @@ -134,18 +134,17 @@ class Build : NukeBuild .DependsOn(Compile) .Executes(() => { - // There aren't any yet - }); + var TestProject = SourceDirectory / "ElectronNET.IntegrationTests" / "ElectronNET.IntegrationTests.csproj"; - Target CreatePackages => _ => _ - .DependsOn(Compile) - .Executes(() => - { - // Packages are created on build + DotNetTest(s => s + .SetProjectFile(TestProject) + .SetConfiguration(Configuration) + .When(_ => GitHubActions.Instance is not null, x => x.SetLoggers("GitHubActions")) + ); }); Target PublishPackages => _ => _ - .DependsOn(CreatePackages) + .DependsOn(Compile) .DependsOn(RunUnitTests) .Executes(() => { @@ -240,7 +239,7 @@ class Build : NukeBuild Target Package => _ => _ .DependsOn(RunUnitTests) - .DependsOn(CreatePackages); + .DependsOn(Compile); Target Default => _ => _ .DependsOn(Package); diff --git a/nuke/_build.csproj b/nuke/_build.csproj index a71fa1b..3258f31 100644 --- a/nuke/_build.csproj +++ b/nuke/_build.csproj @@ -11,11 +11,11 @@ - + - + diff --git a/src/ElectronNET/build/ElectronNET.Build.dll b/src/ElectronNET/build/ElectronNET.Build.dll index 2f3e380ea4a9d07e1eed365d06b6c0d7845069de..c850ff39c5c2e15f819f51f90fb83cb8b80b3306 100644 GIT binary patch delta 671 zcmZp0XmFU&!D9FBV9UfF8Ah>*E5rE?nlUi=GcYhPI5050V4kQb%#*;tz{9}6aKMy- zA!M>5lg{KwMt{Z^lUFi^Gk%@S$Rx~qMUa7kak8PL`Q`woKg^70Hv6*0vIy^HQe;SG z0Fl`Y2beS&iWzoK-pi$5FUO?E;LQ-kq{k4(xuu1vQHn{LWwN<}d8(z6QA%2xVXAqep{0REQmTceq2Xi?@diYLSM z*ch3c81yIW%W4N|GZ-_ZG9)orFqkqJFqkt~f>}lkDGVkIX$+PO$qeRT@l*y&1|tTL zcp5_*gCRpIgE>PYgCT<@g8_pDLlQ$Og9U>ngCT?A;Q48AhpzE5rGYnlUi=GcYhPI504LV4kQb%#*;tz{9}6aKw~> zA!M>5lg{KwMt{Z+lUFi^Gya^+$Rx~qLy&=iak8PL`Q`woKg^65Hv6*0vIy^IQe;SG z0Fl`YN0>AjiW&A#-pi$5ufU|o;LQ-mq{k4-i9*%GoL=v^ce>IL6y0H7{?nl|;HOR9PiV8OXA*`-hq=tT{MSF5T04YX-3d zM6yplCn3%FbMh+*qs - 0.1.0.0 + 0.1.0 ElectronNET.Core Gregor Biswanger, Florian Rappl, softworkz Electron.NET From c37f98dcd629cac96d9859ed097dd447d82db0a0 Mon Sep 17 00:00:00 2001 From: Florian Rappl Date: Wed, 12 Nov 2025 14:27:30 +0100 Subject: [PATCH 3/3] Added the test logger --- .../ElectronNET.IntegrationTests.csproj | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/ElectronNET.IntegrationTests/ElectronNET.IntegrationTests.csproj b/src/ElectronNET.IntegrationTests/ElectronNET.IntegrationTests.csproj index f13ae15..0c3ac24 100644 --- a/src/ElectronNET.IntegrationTests/ElectronNET.IntegrationTests.csproj +++ b/src/ElectronNET.IntegrationTests/ElectronNET.IntegrationTests.csproj @@ -12,10 +12,12 @@ enable enable false + true + all