Commit a1695d0e authored by carlosperate's avatar carlosperate

Electron: Update with latest boilerplate changes.

This include dependencies updated to the latest versions.
parent caeac622
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
"target": "development" "target": "development"
}, },
"dependencies": { "dependencies": {
"fs-jetpack": "^0.6.4" "fs-jetpack": "^0.6.5"
}, },
"repository" : { "repository" : {
"type" : "git", "type" : "git",
......
{ {
"devDependencies": { "devDependencies": {
"asar": "^0.7.1", "asar": "^0.7.2",
"electron-prebuilt": "^0.28.2", "electron-prebuilt": "^0.28.3",
"esperanto": "^0.6.17", "esperanto": "^0.7.2",
"fs-jetpack": "^0.6.5", "fs-jetpack": "^0.6.5",
"gulp": "^3.8.8", "gulp": "^3.9.0",
"gulp-less": "^1.3.6", "gulp-less": "^3.0.3",
"gulp-util": "^3.0.1", "gulp-util": "^3.0.6",
"q": "^1.0.1", "q": "^1.4.1",
"tree-kill": "^0.1.1",
"vinyl-map": "^1.0.1", "vinyl-map": "^1.0.1",
"yargs": "^1.3.1" "yargs": "^3.13.0"
}, },
"optionalDependencies": { "optionalDependencies": {
"appdmg": "^0.3.1", "appdmg": "^0.3.2",
"rcedit": "^0.3.0" "rcedit": "^0.3.0"
}, },
"scripts": { "scripts": {
......
...@@ -4,7 +4,9 @@ var Q = require('q'); ...@@ -4,7 +4,9 @@ var Q = require('q');
var electron = require('electron-prebuilt'); var electron = require('electron-prebuilt');
var pathUtil = require('path'); var pathUtil = require('path');
var childProcess = require('child_process'); var childProcess = require('child_process');
var kill = require('tree-kill');
var utils = require('./utils'); var utils = require('./utils');
var watch;
var gulpPath = pathUtil.resolve('./node_modules/.bin/gulp'); var gulpPath = pathUtil.resolve('./node_modules/.bin/gulp');
if (process.platform === 'win32') { if (process.platform === 'win32') {
...@@ -30,7 +32,7 @@ var runBuild = function () { ...@@ -30,7 +32,7 @@ var runBuild = function () {
}; };
var runGulpWatch = function () { var runGulpWatch = function () {
var watch = childProcess.spawn(gulpPath, [ watch = childProcess.spawn(gulpPath, [
'watch', 'watch',
'--env=' + utils.getEnvName(), '--env=' + utils.getEnvName(),
'--color' '--color'
...@@ -43,10 +45,6 @@ var runGulpWatch = function () { ...@@ -43,10 +45,6 @@ var runGulpWatch = function () {
// Just respawn it then. // Just respawn it then.
runGulpWatch(); runGulpWatch();
}); });
process.on('exit', function () {
watch.kill();
});
}; };
var runApp = function () { var runApp = function () {
...@@ -56,8 +54,10 @@ var runApp = function () { ...@@ -56,8 +54,10 @@ var runApp = function () {
app.on('close', function (code) { app.on('close', function (code) {
// User closed the app. Kill the host process. // User closed the app. Kill the host process.
kill(watch.pid, 'SIGKILL', function () {
process.exit(); process.exit();
}); });
});
}; };
runBuild() runBuild()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment