()
+ .AddInteractiveServerRenderMode();
+
+app.Run();
+
+static async Task ElectronAppReady()
+{
+ var window = await Electron.WindowManager.CreateWindowAsync(new BrowserWindowOptions
+ {
+ IsRunningBlazor = true,
+ Width = 1152,
+ Height = 940,
+ Show = false,
+ });
+
+ window.OnReadyToShow += () => window.Show();
+}
diff --git a/src/ElectronNET.Templates/templates/blazor/Properties/PublishProfiles/linux-x64.pubxml b/src/ElectronNET.Templates/templates/blazor/Properties/PublishProfiles/linux-x64.pubxml
new file mode 100644
index 00000000..4aa6f5d5
--- /dev/null
+++ b/src/ElectronNET.Templates/templates/blazor/Properties/PublishProfiles/linux-x64.pubxml
@@ -0,0 +1,17 @@
+
+
+
+
+ true
+ false
+ false
+ Release
+ FileSystem
+ publish\$(Configuration)\$(TargetFramework)\$(RuntimeIdentifier)\
+ FileSystem
+ <_TargetId>Folder
+ net8.0
+ linux-x64
+ true
+
+
diff --git a/src/ElectronNET.Templates/templates/blazor/Properties/PublishProfiles/osx-arm64.pubxml b/src/ElectronNET.Templates/templates/blazor/Properties/PublishProfiles/osx-arm64.pubxml
new file mode 100644
index 00000000..d6d13321
--- /dev/null
+++ b/src/ElectronNET.Templates/templates/blazor/Properties/PublishProfiles/osx-arm64.pubxml
@@ -0,0 +1,17 @@
+
+
+
+
+ true
+ false
+ false
+ Release
+ FileSystem
+ publish\$(Configuration)\$(TargetFramework)\$(RuntimeIdentifier)\
+ FileSystem
+ <_TargetId>Folder
+ net8.0
+ osx-arm64
+ true
+
+
diff --git a/src/ElectronNET.Templates/templates/blazor/Properties/PublishProfiles/win-x64.pubxml b/src/ElectronNET.Templates/templates/blazor/Properties/PublishProfiles/win-x64.pubxml
new file mode 100644
index 00000000..e2fb6d00
--- /dev/null
+++ b/src/ElectronNET.Templates/templates/blazor/Properties/PublishProfiles/win-x64.pubxml
@@ -0,0 +1,17 @@
+
+
+
+
+ true
+ false
+ false
+ Release
+ FileSystem
+ publish\$(Configuration)\$(TargetFramework)\$(RuntimeIdentifier)\
+ FileSystem
+ <_TargetId>Folder
+ net8.0
+ win-x64
+ true
+
+
diff --git a/src/ElectronNET.Templates/templates/blazor/Properties/electron-builder.json b/src/ElectronNET.Templates/templates/blazor/Properties/electron-builder.json
new file mode 100644
index 00000000..168dbf11
--- /dev/null
+++ b/src/ElectronNET.Templates/templates/blazor/Properties/electron-builder.json
@@ -0,0 +1,22 @@
+{
+ "compression": "maximum",
+ "linux": {
+ "target": [ "AppImage" ],
+ "executableArgs": [ "--no-sandbox" ]
+ },
+ "win": {
+ "target": [
+ {
+ "target": "nsis",
+ "arch": "x64"
+ }
+ ]
+ },
+ "mac": {
+ "target": [ "dmg" ]
+ },
+ "nsis": {
+ "oneClick": true,
+ "perMachine": false
+ }
+}
diff --git a/src/ElectronNET.Templates/templates/blazor/Properties/launchSettings.json b/src/ElectronNET.Templates/templates/blazor/Properties/launchSettings.json
new file mode 100644
index 00000000..42be4365
--- /dev/null
+++ b/src/ElectronNET.Templates/templates/blazor/Properties/launchSettings.json
@@ -0,0 +1,11 @@
+{
+ "profiles": {
+ "ElectronBlazorApp": {
+ "commandName": "Project",
+ "environmentVariables": {
+ "ASPNETCORE_ENVIRONMENT": "Development"
+ },
+ "applicationUrl": "http://localhost:8001/"
+ }
+ }
+}
diff --git a/src/ElectronNET.Templates/templates/blazor/appsettings.Development.json b/src/ElectronNET.Templates/templates/blazor/appsettings.Development.json
new file mode 100644
index 00000000..0c208ae9
--- /dev/null
+++ b/src/ElectronNET.Templates/templates/blazor/appsettings.Development.json
@@ -0,0 +1,8 @@
+{
+ "Logging": {
+ "LogLevel": {
+ "Default": "Information",
+ "Microsoft.AspNetCore": "Warning"
+ }
+ }
+}
diff --git a/src/ElectronNET.Templates/templates/blazor/appsettings.json b/src/ElectronNET.Templates/templates/blazor/appsettings.json
new file mode 100644
index 00000000..10f68b8c
--- /dev/null
+++ b/src/ElectronNET.Templates/templates/blazor/appsettings.json
@@ -0,0 +1,9 @@
+{
+ "Logging": {
+ "LogLevel": {
+ "Default": "Information",
+ "Microsoft.AspNetCore": "Warning"
+ }
+ },
+ "AllowedHosts": "*"
+}
diff --git a/src/ElectronNET.Templates/templates/blazor/wwwroot/app.css b/src/ElectronNET.Templates/templates/blazor/wwwroot/app.css
new file mode 100644
index 00000000..5eff1cb4
--- /dev/null
+++ b/src/ElectronNET.Templates/templates/blazor/wwwroot/app.css
@@ -0,0 +1,49 @@
+:root {
+ color-scheme: light dark;
+}
+
+body {
+ margin: 0;
+ font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
+ line-height: 1.5;
+}
+
+.page {
+ display: flex;
+ flex-direction: column;
+ min-height: 100vh;
+}
+
+.nav-menu {
+ display: flex;
+ gap: 1rem;
+ padding: 0.75rem 1.5rem;
+ background-color: #1b1b1f;
+}
+
+.nav-menu a {
+ color: #d7d7d7;
+ text-decoration: none;
+}
+
+.nav-menu a.active {
+ color: #fff;
+ font-weight: 600;
+}
+
+main {
+ padding: 1.5rem;
+}
+
+.btn {
+ padding: 0.5rem 1rem;
+ border: none;
+ border-radius: 0.25rem;
+ background-color: #1b6ec2;
+ color: #fff;
+ cursor: pointer;
+}
+
+.btn:hover {
+ background-color: #1861ac;
+}
diff --git a/src/ElectronNET.WebApp/Controllers/UpdateController.cs b/src/ElectronNET.WebApp/Controllers/UpdateController.cs
index e145ec77..84bcfde7 100644
--- a/src/ElectronNET.WebApp/Controllers/UpdateController.cs
+++ b/src/ElectronNET.WebApp/Controllers/UpdateController.cs
@@ -29,9 +29,6 @@ public IActionResult Index()
Electron.IpcMain.On("auto-update", async (args) =>
{
- // Electron.NET CLI Command for deploy:
- // electronize build /target win /electron-params --publish=always
-
var currentVersion = await Electron.App.GetVersionAsync();
var updateCheckResult = await Electron.AutoUpdater.CheckForUpdatesAndNotifyAsync();
var availableVersion = updateCheckResult.UpdateInfo.Version;
diff --git a/src/ElectronNET.WebApp/ElectronHostHook/package-lock.json b/src/ElectronNET.WebApp/ElectronHostHook/package-lock.json
index 72216078..e2ad3adf 100644
--- a/src/ElectronNET.WebApp/ElectronHostHook/package-lock.json
+++ b/src/ElectronNET.WebApp/ElectronHostHook/package-lock.json
@@ -540,9 +540,9 @@
"license": "MIT"
},
"node_modules/brace-expansion": {
- "version": "1.1.14",
- "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.14.tgz",
- "integrity": "sha512-MWPGfDxnyzKU7rNOW9SP/c50vi3xrmrua/+6hfPbCS2ABNWfx24vPidzvC7krjU/RTo235sV776ymlsMtGKj8g==",
+ "version": "1.1.18",
+ "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.18.tgz",
+ "integrity": "sha512-Edep/X9fGqVNmzKBVsDYIOtD+z1tuezV70LBjdCst9Tqu76lsnvRiZ6oTic1n+/BIwX6QDGAO94PN4N2SADvtw==",
"license": "MIT",
"dependencies": {
"balanced-match": "^1.0.0",
@@ -1351,9 +1351,9 @@
"license": "ISC"
},
"node_modules/js-yaml": {
- "version": "4.3.0",
- "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.3.0.tgz",
- "integrity": "sha512-1td788aAnnZ5qs7V2QIRl1owjtYpbKt749Y3xauqQgwIIGF/xXWz1wMTEBx5O3LK3lXLVuqXPdPxj2BoFHaW9Q==",
+ "version": "4.3.1",
+ "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.3.1.tgz",
+ "integrity": "sha512-CY6crGq313MX8GkwvB7tzgp99vjQxY1++5y10/BKN/GUfHqWaOGQMNZkBvqSzsZKWk/ijwHlWzzkLulsGHhjWQ==",
"dev": true,
"funding": [
{
@@ -1811,9 +1811,9 @@
}
},
"node_modules/readdir-glob/node_modules/brace-expansion": {
- "version": "2.1.1",
- "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.1.1.tgz",
- "integrity": "sha512-WR1cURNjuvBLMZBMbqM0UoE+WAfdUcEV1ccD8PVBVOI+Z3ND4+SZbN8RsfT2bMuG1qwz5RFvPukSZm5fF2D5eA==",
+ "version": "2.1.4",
+ "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.1.4.tgz",
+ "integrity": "sha512-hGfVzPxthbf3+2yjg/RBs60cB0FhqBS/zvdV/4wn4/BmN0bNMMHPc4V/BbFieqf1TKAGGAHnY4eSjajCl0f2Xg==",
"license": "MIT",
"dependencies": {
"balanced-match": "^1.0.0"
diff --git a/src/ElectronNET.WebApp/ElectronNET.WebApp.csproj b/src/ElectronNET.WebApp/ElectronNET.WebApp.csproj
index bf43c579..6c2c3999 100644
--- a/src/ElectronNET.WebApp/ElectronNET.WebApp.csproj
+++ b/src/ElectronNET.WebApp/ElectronNET.WebApp.csproj
@@ -75,8 +75,8 @@
-
-
+
+
diff --git a/src/ElectronNET.WebApp/Views/HostHook/Index.cshtml b/src/ElectronNET.WebApp/Views/HostHook/Index.cshtml
index 7dbbed0c..7c5c2673 100644
--- a/src/ElectronNET.WebApp/Views/HostHook/Index.cshtml
+++ b/src/ElectronNET.WebApp/Views/HostHook/Index.cshtml
@@ -8,7 +8,7 @@
The HostHook API allows you to execute your own JavaScript/TypeScript code on the host process.
- Create first an ElectronHostHook directory via the Electron.NET CLI, with the following command: electronize add hosthook.
+ Create first an ElectronHostHook directory with a package.json and a JavaScript file.
In this directory you can install any NPM packages and embed your own JavaScript/TypeScript code. It is also possible to respond to events from the host process.
You find the sample source code in Controllers\HostHookController.cs and in the ElectronHostHook folder.
diff --git a/src/ElectronNET.sln b/src/ElectronNET.sln
index 43fbaafe..c19b2cbd 100644
--- a/src/ElectronNET.sln
+++ b/src/ElectronNET.sln
@@ -29,6 +29,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "!Config", "!Config", "{02EA
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ElectronNET.AspNet", "ElectronNET.AspNet\ElectronNET.AspNet.csproj", "{DD10D21A-D131-1D9C-33F9-406046E0C5B0}"
EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ElectronNET.Templates", "ElectronNET.Templates\ElectronNET.Templates.csproj", "{3F2A1D64-9C71-4E1B-9A2D-5C7B0E4F8A11}"
+EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ElectronNET.ConsoleApp", "ElectronNET.ConsoleApp\ElectronNET.ConsoleApp.csproj", "{EE38A326-5DE8-AF09-9EB9-DF0878938783}"
ProjectSection(ProjectDependencies) = postProject
{1C5FD66E-A1C6-C436-DF7C-3ECE4FEDDFE6} = {1C5FD66E-A1C6-C436-DF7C-3ECE4FEDDFE6}
@@ -99,6 +101,10 @@ Global
{DD10D21A-D131-1D9C-33F9-406046E0C5B0}.Debug|Any CPU.Build.0 = Debug|Any CPU
{DD10D21A-D131-1D9C-33F9-406046E0C5B0}.Release|Any CPU.ActiveCfg = Release|Any CPU
{DD10D21A-D131-1D9C-33F9-406046E0C5B0}.Release|Any CPU.Build.0 = Release|Any CPU
+ {3F2A1D64-9C71-4E1B-9A2D-5C7B0E4F8A11}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {3F2A1D64-9C71-4E1B-9A2D-5C7B0E4F8A11}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {3F2A1D64-9C71-4E1B-9A2D-5C7B0E4F8A11}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {3F2A1D64-9C71-4E1B-9A2D-5C7B0E4F8A11}.Release|Any CPU.Build.0 = Release|Any CPU
{EE38A326-5DE8-AF09-9EB9-DF0878938783}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{EE38A326-5DE8-AF09-9EB9-DF0878938783}.Debug|Any CPU.Build.0 = Debug|Any CPU
{EE38A326-5DE8-AF09-9EB9-DF0878938783}.Release|Any CPU.ActiveCfg = Release|Any CPU
@@ -131,6 +137,7 @@ Global
{829FC339-4785-4229-ABA5-53ADB544DA00} = {1BB6F634-2831-4496-83A6-BC6761DCEC8D}
{8860606D-6847-F22A-5AED-DF4E0984DD24} = {1BB6F634-2831-4496-83A6-BC6761DCEC8D}
{DD10D21A-D131-1D9C-33F9-406046E0C5B0} = {1BB6F634-2831-4496-83A6-BC6761DCEC8D}
+ {3F2A1D64-9C71-4E1B-9A2D-5C7B0E4F8A11} = {1BB6F634-2831-4496-83A6-BC6761DCEC8D}
{EE38A326-5DE8-AF09-9EB9-DF0878938783} = {EDCBFC49-2AEE-4BAF-9368-4409298C52FC}
{015CB06B-6CAE-209F-E050-21C3ACA5FE9F} = {985D39A7-5216-4945-8167-2FD0CB387BD8}
{06CAADC7-DE5B-47B4-AB2A-E9501459A2D1} = {D36CDFFD-3438-42E4-A7FF-88BA19AC4964}
diff --git a/src/ElectronNET/ElectronNET.csproj b/src/ElectronNET/ElectronNET.csproj
index 2298cd7e..38524f20 100644
--- a/src/ElectronNET/ElectronNET.csproj
+++ b/src/ElectronNET/ElectronNET.csproj
@@ -3,7 +3,7 @@
- net6.0;net8.0;net10.0
+ $(ElectronNetTargetFrameworks)
..\..\artifacts
$(PackageNamePrefix)
$(PackageId)
diff --git a/src/ElectronNET/build/ElectronNET.Build.dll b/src/ElectronNET/build/ElectronNET.Build.dll
index c850ff39..0455b561 100644
Binary files a/src/ElectronNET/build/ElectronNET.Build.dll and b/src/ElectronNET/build/ElectronNET.Build.dll differ
diff --git a/src/ElectronNET/build/ElectronNET.Core.props b/src/ElectronNET/build/ElectronNET.Core.props
index 13578cae..4b4eed4a 100644
--- a/src/ElectronNET/build/ElectronNET.Core.props
+++ b/src/ElectronNET/build/ElectronNET.Core.props
@@ -4,19 +4,21 @@
30.4.0
26.0
-
- $(RuntimeIdentifier)
-
- $([System.Runtime.InteropServices.RuntimeInformation]::RuntimeIdentifier)
-
- win-$([System.Runtime.InteropServices.RuntimeInformation]::OSArchitecture.ToString().ToLower())
+
true
- $(MSBuildProjectName.Replace(".", "-").ToLower())
+ $(MSBuildProjectName.Replace(".", "-").ToLower())
electron-builder.json
- $(MSBuildProjectName)
+ $(MSBuildProjectName)
+
+ ../..
+
+ false
diff --git a/src/ElectronNET/build/ElectronNET.Core.targets b/src/ElectronNET/build/ElectronNET.Core.targets
index 962ed6fa..f615ce37 100644
--- a/src/ElectronNET/build/ElectronNET.Core.targets
+++ b/src/ElectronNET/build/ElectronNET.Core.targets
@@ -1,10 +1,16 @@
-
+
win
- $(Title)
- $(ElectronPackageId)
+ $(Title)
+ $(ElectronPackageId)
+
+
+
+
+ $(ElectronExecutableName)
@@ -19,6 +25,7 @@
+
diff --git a/src/ElectronNET/build/ElectronNET.LateImport.targets b/src/ElectronNET/build/ElectronNET.LateImport.targets
index 9019c09f..1e405ec4 100644
--- a/src/ElectronNET/build/ElectronNET.LateImport.targets
+++ b/src/ElectronNET/build/ElectronNET.LateImport.targets
@@ -52,7 +52,7 @@
-
+
@@ -60,7 +60,7 @@
-
+
@@ -95,8 +95,24 @@
+
+
+
+
+ $(RuntimeIdentifier)
+
+ $([System.Runtime.InteropServices.RuntimeInformation]::RuntimeIdentifier)
+
+ win-$([System.Runtime.InteropServices.RuntimeInformation]::OSArchitecture.ToString().ToLower())
+
+
+
+
+
+
-
+
@@ -154,7 +170,9 @@
<_NonIntermediatePublishDir>$(PublishDir)
$(PublishDir)
- $(IntermediateOutputPath)PubTmp\
+
+ $(ElectronIntermediatePublishDir)
+ $(IntermediateOutputPath)PubTmp\
@@ -370,7 +388,7 @@
-
+
x64
@@ -443,13 +461,13 @@
-
+
-
+
-
+
<_NpmCmd>node node_modules/electron/install.js
@@ -458,13 +476,13 @@
<_NpmCmd Condition="'$(IsLinuxWsl)' == 'true'">wsl bash -ic '$(_NpmCmd)'
-
+
-
+
-
+
@@ -599,11 +617,11 @@ For more information, see: https://github.com/ElectronNET/Electron.NET/wiki/Migr
<_NpmAppDepsCmd Condition="'$(IsLinuxWsl)' == 'true'">wsl bash -ic '$(_NpmAppDepsCmd)'
-
+
-
+
+
@@ -629,11 +648,11 @@ For more information, see: https://github.com/ElectronNET/Electron.NET/wiki/Migr
<_NpmCmd Condition="'$(IsLinuxWsl)' == 'true'">wsl bash -ic '$(_NpmCmd)'
-
+
-
+
@@ -653,18 +672,15 @@ For more information, see: https://github.com/ElectronNET/Electron.NET/wiki/Migr
- <_NpxCmd>npx electron-builder --config=./$(ElectronBuilderJson)
- <_NpxCmd Condition="'$(IsLinuxWsl)' == 'true'">$(_NpxCmd) --$(ElectronPlatform)
- <_NpxCmd Condition="'$(IsLinuxWsl)' == 'true'">$(_NpxCmd) --$(ElectronArch)
- <_NpxCmd>$(_NpxCmd) -c.electronVersion=$(ElectronVersion) -c.directories.output "$(ElectronPublishUrlFullPath)" $(ElectronPaParams)
+ <_NpxCmd>npx electron-builder -c.$(ElectronPlatform).defaultArch=$(ElectronArch) --config=./$(ElectronBuilderJson) -c.electronVersion=$(ElectronVersion) --$(ElectronPlatform) --$(ElectronArch) -c.directories.output "$(ElectronPublishUrlFullPath)" $(ElectronPaParams)
<_NpxCmd Condition="'$(IsLinuxWsl)' == 'true'">wsl bash -ic '$(_NpxCmd)'
-
+
-
+
diff --git a/src/ElectronNET/build/ElectronNET.MigrationChecks.targets b/src/ElectronNET/build/ElectronNET.MigrationChecks.targets
index ab138a5d..d928e7fc 100644
--- a/src/ElectronNET/build/ElectronNET.MigrationChecks.targets
+++ b/src/ElectronNET/build/ElectronNET.MigrationChecks.targets
@@ -9,10 +9,22 @@
ElectronCheckNoManifestJson;
ElectronCheckElectronBuilderJson;
ElectronCheckNoParentPaths;
- ElectronCheckPubxmlFiles
+ ElectronCheckPubxmlFiles;
+ ElectronCheckHostHookFolder
+
+
+ <_ElectronCheckExcludes>$(MSBuildProjectDirectory)\bin\**\*;$(MSBuildProjectDirectory)\obj\**\*;$(MSBuildProjectDirectory)\publish\**\*;$(MSBuildProjectDirectory)\node_modules\**\*;$(MSBuildProjectDirectory)\.electron\**\*
+ <_ElectronCheckExcludes Condition="'$(BaseOutputPath)' != ''">$(_ElectronCheckExcludes);$([MSBuild]::NormalizeDirectory('$(MSBuildProjectDirectory)', '$(BaseOutputPath)'))**\*
+ <_ElectronCheckExcludes Condition="'$(BaseIntermediateOutputPath)' != ''">$(_ElectronCheckExcludes);$([MSBuild]::NormalizeDirectory('$(MSBuildProjectDirectory)', '$(BaseIntermediateOutputPath)'))**\*
+
+
+ $(_ElectronCheckExcludes)" />
+
<_InvalidPackageLockJson Include="$(MSBuildProjectDirectory)\**\package-lock.json"
- Exclude="$(MSBuildProjectDirectory)\ElectronHostHook\**\package-lock.json;
- $(MSBuildProjectDirectory)\bin\**\package-lock.json;
- $(MSBuildProjectDirectory)\obj\**\package-lock.json;
- $(MSBuildProjectDirectory)\publish\**\package-lock.json;
- $(MSBuildProjectDirectory)\node_modules\**\package-lock.json" />
+ Exclude="$(MSBuildProjectDirectory)\package-lock.json;
+ $(MSBuildProjectDirectory)\ElectronHostHook\**\package-lock.json;
+ $(_ElectronCheckExcludes)" />
@@ -141,10 +150,7 @@ For more information, see: https://github.com/ElectronNET/Electron.NET/wiki/Migr
<_InvalidManifestJson Include="$(MSBuildProjectDirectory)\**\electron.manifest.json;$(MSBuildProjectDirectory)\**\electron-manifest.json"
- Exclude="$(MSBuildProjectDirectory)\bin\**\*;
- $(MSBuildProjectDirectory)\obj\**\*;
- $(MSBuildProjectDirectory)\publish\**\*;
- $(MSBuildProjectDirectory)\node_modules\**\*" />
+ Exclude="$(_ElectronCheckExcludes)" />
@@ -187,10 +193,7 @@ MIGRATION REQUIRED:
<_ElectronBuilderJsonWrongLocation Include="$(MSBuildProjectDirectory)\**\electron-builder.json"
Exclude="$(MSBuildProjectDirectory)\Properties\electron-builder.json;
- $(MSBuildProjectDirectory)\bin\**\*;
- $(MSBuildProjectDirectory)\obj\**\*;
- $(MSBuildProjectDirectory)\publish\**\*;
- $(MSBuildProjectDirectory)\node_modules\**\*" />
+ $(_ElectronCheckExcludes)" />
@@ -296,10 +299,11 @@ For more information, see: https://github.com/ElectronNET/Electron.NET/wiki/Migr
-
+
<_PubxmlFileInfoWithFlags Include="@(_PubxmlFileInfo)" Condition="'%(Identity)' != ''">
$([System.Text.RegularExpressions.Regex]::IsMatch('%(FileContent)', '<WebPublishMethod>'))
+ $([System.Text.RegularExpressions.Regex]::IsMatch('%(FileContent)', '<ProjectGuid>'))
@@ -309,10 +313,10 @@ For more information, see: https://github.com/ElectronNET/Electron.NET/wiki/Migr
Condition="'$(_IsAspNetProject)' == 'true' AND '%(HasWebPublishMethod)' == 'False'" />
-
+
<_ConsolePubxmlWithAspNetProperties Include="@(_PubxmlFileInfoWithFlags)"
- Condition="'$(_IsAspNetProject)' != 'true' AND '%(HasWebPublishMethod)' == 'True'" />
+ Condition="'$(_IsAspNetProject)' != 'true' AND ('%(HasWebPublishMethod)' == 'True' OR '%(HasProjectGuid)' == 'True')" />
@@ -336,7 +340,7 @@ For more information, see: https://github.com/ElectronNET/Electron.NET/wiki/Migr
+
+
+
+
+ <_HostHookTsFiles Include="$(MSBuildProjectDirectory)\ElectronHostHook\*.ts" />
+
+
+
+ <_HasHostHookTsFiles>false
+ <_HasHostHookTsFiles Condition="@(_HostHookTsFiles->Count()) > 0">true
+
+
+
+
+
+
+
+
diff --git a/src/ElectronNET/build/ElectronNETRules.Project.xaml b/src/ElectronNET/build/ElectronNETRules.Project.xaml
index 0331ae8f..bc55308c 100644
--- a/src/ElectronNET/build/ElectronNETRules.Project.xaml
+++ b/src/ElectronNET/build/ElectronNETRules.Project.xaml
@@ -553,6 +553,30 @@
Category="General">
+
+
+
+
+
+
+
+
+
+
+
+
- 0.5.2
+ 0.6.0
ElectronNET.Core
Gregor Biswanger, Florian Rappl, softworkz
Electron.NET
@@ -18,6 +18,7 @@
$(Version)
$(Version)$(VersionPostFix)
$(Version)
+ net6.0;net8.0;net10.0