Skip to content

Commit

Permalink
use fs-extra to allow moving of files over partitions; set files for …
Browse files Browse the repository at this point in the history
…npm distribution
  • Loading branch information
Mairu committed Jul 31, 2017
1 parent 3de3aae commit 780a85a
Show file tree
Hide file tree
Showing 8 changed files with 17 additions and 71 deletions.
1 change: 0 additions & 1 deletion .npm/package/.gitignore

This file was deleted.

7 changes: 0 additions & 7 deletions .npm/package/README

This file was deleted.

55 changes: 0 additions & 55 deletions .npm/package/npm-shrinkwrap.json

This file was deleted.

2 changes: 1 addition & 1 deletion HISTORY.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
3.0.0 / 2017-07-13
3.0.0 / 2017-07-31
==================
* Removed the atmosphere part of electrify -> created new meteor-electrify-client npm package
* Updated to use current versions of Electron (1.6.11) and electron-packager
Expand Down
4 changes: 2 additions & 2 deletions lib/app.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
var _ = require('lodash');

var fs = require('fs');
var fs = require('fs-extra');
var spawn = require('child_process').spawn;
var join = require('path').join;
var shell = require('shelljs');
Expand Down Expand Up @@ -138,7 +138,7 @@ App.prototype.bundle_meteor = function( /* server_url, */ done) {

// move bundled meteor into .electrify
shell.rm('-rf', electrify_app_dir);
shell.mv(bundled_dir, electrify_app_dir);
fs.moveSync(bundled_dir, electrify_app_dir);
shell.rm('-rf', tmp_dir);

self.log.info('ensuring meteor dependencies');
Expand Down
4 changes: 2 additions & 2 deletions lib/electron.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
var _ = require('lodash');
var fs = require('fs');
var fs = require('fs-extra');
var path = require('path');
var join = path.join;
var shell = require('shelljs');
Expand Down Expand Up @@ -114,7 +114,7 @@ Electron.prototype.package = function(packager_options, done) {

// moving packaged app to .dist folder
shell.rm('-rf', self.$.env.app.dist);
shell.mv(tmp_package_dir, self.$.env.app.dist);
fs.moveSync(tmp_package_dir, self.$.env.app.dist);
self.log.info('wrote new app to ', self.$.env.app.dist);

if(done) done();
Expand Down
7 changes: 4 additions & 3 deletions make.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,8 @@ target['test.cover'] = function(done){
LOGELECTRIFY: 'ALL',
TESTELECTRIFY: true
}, process.env)
}).on('exit', function(){
if(done) done();
}).on('exit', function(code){
if(done) done(code);
});
};

Expand Down Expand Up @@ -117,7 +117,7 @@ target['test.cover.send'] = function() {
process.exit(1);
}

target['test.cover'](function(){
target['test.cover'](function(code){
var lcov_path = path.join(__dirname, 'coverage', 'lcov.info');
spawn(node_bin, [CODECLIMATE_TEST_REPORTER], {
stdio: [
Expand All @@ -127,6 +127,7 @@ target['test.cover.send'] = function() {
]
}).on('exit', function() {
console.log('coverage sent to codeclimate');
process.exit(code);
});
});
};
Expand Down
8 changes: 8 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,21 @@
"engines": {
"node": ">=4.0.0"
},
"files": [
"bin",
"lib",
"LICENCE",
"README.md",
"HISTORY.md"
],
"description": "Package your Meteor apps with Electron, and butter.",
"author": "Sebastian Große",
"license": "MIT",
"dependencies": {
"commander": "^2.10.0",
"electron": "^1.6.11",
"electron-packager": "^8.7.1",
"fs-extra": "^4.0.0",
"lodash": "^3.10.1",
"server-destroy": "^1.0.1",
"shelljs": "^0.7.8",
Expand Down

0 comments on commit 780a85a

Please sign in to comment.