From e9aeada4e8f2d04d22c1d0e9c4f31ad09a6d3744 Mon Sep 17 00:00:00 2001 From: Robert Muehsig Date: Thu, 5 Oct 2017 23:37:52 +0200 Subject: [PATCH] obj folder --- ElectronNET.CLI/Commands/BuildCommand.cs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ElectronNET.CLI/Commands/BuildCommand.cs b/ElectronNET.CLI/Commands/BuildCommand.cs index 1feff18..720b509 100644 --- a/ElectronNET.CLI/Commands/BuildCommand.cs +++ b/ElectronNET.CLI/Commands/BuildCommand.cs @@ -18,8 +18,10 @@ namespace ElectronNET.CLI.Commands { Console.WriteLine("Build Windows Application..."); - string currentAssemblyPath = AppDomain.CurrentDomain.BaseDirectory; - string tempPath = Path.Combine(currentAssemblyPath, "Host"); + string tempPath = Path.Combine(Directory.GetCurrentDirectory(), "obj", "desktop"); + + Console.WriteLine("Executing dotnet publish in this directory: " + tempPath); + ProcessHelper.CmdExecute("dotnet publish -r win10-x64 --output " + Path.Combine(tempPath, "bin"), Directory.GetCurrentDirectory()); if (Directory.Exists(tempPath) == false) @@ -39,6 +41,8 @@ namespace ElectronNET.CLI.Commands Console.WriteLine("Build Electron Desktop Application..."); string buildPath = Path.Combine(Directory.GetCurrentDirectory(), "bin", "desktop"); + Console.WriteLine("Executing electron magic in this directory: " + buildPath); + // Need a solution for --asar support ProcessHelper.CmdExecute($"electron-packager . --platform=win32 --arch=x64 --electronVersion=1.7.8 --out=\"{buildPath}\" --overwrite", tempPath);