mirror of
https://github.com/ElectronNET/Electron.NET.git
synced 2026-09-21 22:45:20 +00:00
Improved argument forwarding
This commit is contained in:
@@ -1,4 +1,10 @@
|
||||
## 0.5.0
|
||||
# 0.5.1
|
||||
|
||||
## ElectronNET.Core
|
||||
|
||||
- Fixed slicing of arguments for packaged applications (#1072)
|
||||
|
||||
# 0.5.0
|
||||
|
||||
## ElectronNET.Core
|
||||
|
||||
|
||||
@@ -133,7 +133,8 @@ if (manifestJsonFile.singleInstance) {
|
||||
// Collect user supplied command line args (excluding those handled by Electron host itself)
|
||||
function getForwardedArgs() {
|
||||
const skipSwitches = new Set(['unpackedelectron', 'unpackeddotnet', 'dotnetpacked']);
|
||||
return process.argv.slice(2).filter(arg => {
|
||||
const sliceIndex = app.isPackaged ? 1 : 2;
|
||||
return process.argv.slice(sliceIndex).filter(arg => {
|
||||
if (!arg) return false;
|
||||
// Node/Electron internal or we already process them
|
||||
if (arg.startsWith('--manifest')) return false;
|
||||
|
||||
Reference in New Issue
Block a user