start refactoring index.js

This commit is contained in:
Iuri Matias 2017-02-19 13:18:43 -05:00
parent 5e4ad9a7e5
commit a8193277da
1 changed files with 15 additions and 15 deletions

View File

@ -37,11 +37,6 @@ var Embark = {
cmd.process(args);
},
generateTemplate: function(templateName, destinationFolder, name) {
var templateGenerator = new TemplateGenerator(templateName);
templateGenerator.generate(destinationFolder, name);
},
initConfig: function(env, options) {
this.logger = new Logger({logLevel: 'debug'});
@ -51,6 +46,21 @@ var Embark = {
},
blockchain: function(env, client) {
var blockchain = Blockchain(this.config.blockchainConfig, client);
blockchain.run({env: env});
},
simulator: function(options) {
var simulator = new Simulator({blockchainConfig: this.config.blockchainConfig});
simulator.run(options);
},
generateTemplate: function(templateName, destinationFolder, name) {
var templateGenerator = new TemplateGenerator(templateName);
templateGenerator.generate(destinationFolder, name);
},
redeploy: function(env) {
var self = this;
async.waterfall([
@ -193,11 +203,6 @@ var Embark = {
});
},
blockchain: function(env, client) {
var blockchain = Blockchain(this.config.blockchainConfig, client);
blockchain.run({env: env});
},
buildAndDeploy: function(done) {
var self = this;
async.waterfall([
@ -340,11 +345,6 @@ var Embark = {
console.log(("unknown platform: " + platform).red);
console.log('try "embark upload ipfs" or "embark upload swarm"'.green);
}
},
simulator: function(options) {
var simulator = new Simulator({blockchainConfig: this.config.blockchainConfig});
simulator.run(options);
}
};