Should not touch process.argv when starting the default_app.
This commit is contained in:
parent
5ce66fca5c
commit
27be89d39a
1 changed files with 2 additions and 2 deletions
|
@ -1,6 +1,7 @@
|
||||||
var app = require('app');
|
var app = require('app');
|
||||||
var dialog = require('dialog');
|
var dialog = require('dialog');
|
||||||
var path = require('path');
|
var path = require('path');
|
||||||
|
var optimist = require('optimist');
|
||||||
|
|
||||||
// Quit when all windows are closed and no other one is listening to this.
|
// Quit when all windows are closed and no other one is listening to this.
|
||||||
app.on('window-all-closed', function() {
|
app.on('window-all-closed', function() {
|
||||||
|
@ -8,8 +9,7 @@ app.on('window-all-closed', function() {
|
||||||
app.quit();
|
app.quit();
|
||||||
});
|
});
|
||||||
|
|
||||||
process.argv.splice(1, 0, 'dummyScript');
|
var argv = optimist(process.argv.slice(1)).argv;
|
||||||
var argv = require('optimist').argv;
|
|
||||||
|
|
||||||
// Start the specified app if there is one specified in command line, otherwise
|
// Start the specified app if there is one specified in command line, otherwise
|
||||||
// start the default app.
|
// start the default app.
|
||||||
|
|
Loading…
Reference in a new issue