[CLI] /absolute-path or /relative-path do not change output location #393

Closed
opened 2026-01-29 16:38:31 +00:00 by claunia · 3 comments
Owner

Originally created by @robertmclaws on GitHub (Oct 10, 2019).

Originally assigned to: @robertmuehsig on GitHub.

Version

  • 5.22.14:

Platform

  • Windows:

Issue Details

Entering the following path into the build process does not change how the project is built: ..\tools\electronize.exe build /target win /absolute-path '$(Build.ArtifactStagingDirectory)\Windows'

Looking into the source code for the CLI, it looks like these lines do indeed set the path that the electron-builder should use, but then the actual builder command uses the path calculated for the internal dotnet build command:

ProcessHelper.CmdExecute($"electron-builder . --config=./bin/electron-builder.json --{platformInfo.ElectronPackerPlatform} --{electronArch} -c.electronVersion=5.0.8 {electronParams}", tempPath);

Steps to Reproduce:

  1. Install .NET Core 2.2 SDK during the build process.
  2. Install .NET Core ElectronNET.CLI Global tool during the build process.
  3. Run command above in the working folder of the project you are building. Example: $(Build.SourcesDirectory)/CloudNimble.AzureDevOpsBuddy.Server
Originally created by @robertmclaws on GitHub (Oct 10, 2019). Originally assigned to: @robertmuehsig on GitHub. ### Version * **5.22.14**: ### Platform * **Windows**: <!-- Enter your issue details below this comment. --> ### Issue Details Entering the following path into the build process does not change how the project is built: `..\tools\electronize.exe build /target win /absolute-path '$(Build.ArtifactStagingDirectory)\Windows'` Looking into the source code for the CLI, it looks like [these lines do indeed set the path](https://github.com/ElectronNET/Electron.NET/blob/master/ElectronNET.CLI/Commands/BuildCommand.cs#L134-L142) that the `electron-builder` should use, but then the[ actual builder command uses the path calculated](https://github.com/ElectronNET/Electron.NET/blob/master/ElectronNET.CLI/Commands/BuildCommand.cs#L163) for the internal `dotnet build` command: ``` ProcessHelper.CmdExecute($"electron-builder . --config=./bin/electron-builder.json --{platformInfo.ElectronPackerPlatform} --{electronArch} -c.electronVersion=5.0.8 {electronParams}", tempPath); ``` ### Steps to Reproduce: 1. Install .NET Core 2.2 SDK during the build process. 2. Install .NET Core ElectronNET.CLI Global tool during the build process. 3. Run command above in the working folder of the project you are building. Example: `$(Build.SourcesDirectory)/CloudNimble.AzureDevOpsBuddy.Server`
claunia added the bug label 2026-01-29 16:38:31 +00:00
Author
Owner

@robertmclaws commented on GitHub (Nov 28, 2019):

@GregorBiswanger Any chance this could get in the 7.30 release too? Should be a quick fix, it's just using the tempPath at the very end instead of buildPath.

Thanks!

@robertmclaws commented on GitHub (Nov 28, 2019): @GregorBiswanger Any chance this could get in the 7.30 release too? Should be a quick fix, it's just using the `tempPath` at the very end instead of `buildPath`. Thanks!
Author
Owner

@GregorBiswanger commented on GitHub (Nov 28, 2019):

@robertmclaws I can not promise yet. @robertmuehsig is normally responsible for the CLI...

@GregorBiswanger commented on GitHub (Nov 28, 2019): @robertmclaws I can not promise yet. @robertmuehsig is normally responsible for the CLI...
Author
Owner

@GregorBiswanger commented on GitHub (May 10, 2020):

I see we have an relative-path param...

Use:
electronize build /target win /relative-path "YOUR PATH"

@GregorBiswanger commented on GitHub (May 10, 2020): I see we have an relative-path param... Use: `electronize build /target win /relative-path "YOUR PATH"`
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/Electron.NET#393