electron/spec/fixtures/api/command-line/main.js

14 lines
298 B
JavaScript
Raw Normal View History

2020-03-20 20:28:31 +00:00
const { app } = require('electron');
app.whenReady().then(() => {
const payload = {
hasSwitch: app.commandLine.hasSwitch('foobar'),
getSwitchValue: app.commandLine.getSwitchValue('foobar')
2020-03-20 20:28:31 +00:00
};
2020-03-20 20:28:31 +00:00
process.stdout.write(JSON.stringify(payload));
process.stdout.end();
2020-03-20 20:28:31 +00:00
app.quit();
});