Skip to content

Commit d5c7bf3

Browse files
committed
fix issue with choosing environment
1 parent 1913a38 commit d5c7bf3

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

bin/embark

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,17 @@ program.command('deploy [env]').description('deploy contracts').action(function(
3030

3131
program.command('build [env]').description('build dapp').action(function(env_) {
3232
var env = env_ || 'development';
33+
exec("grunt clean");
34+
exec("grunt deploy_contracts:" + env);
3335
exec('grunt build:' + env);
3436
});
3537

36-
program.command('release ipfs [env]').description('build dapp and make it available in ipfs').action(function(env_) {
38+
program.command('ipfs [env]').description('build dapp and make it available in ipfs').action(function(env_) {
3739
var env = env_ || 'development';
38-
exec('grunt release_ipfs:' + env);
40+
if (exec("grunt clean").code != 0) { exit(); }
41+
if (exec("grunt deploy_contracts:" + env).code != 0) { exit(); }
42+
if (exec('grunt build:' + env).code != 0) { exit(); }
43+
if (exec('grunt ipfs:' + env).code != 0) { exit(); }
3944
});
4045

4146
program.command('run [env]').description('run dapp').action(function(env_) {

tasks/tasks.coffee

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,4 @@ module.exports = (grunt) ->
22

33
grunt.registerTask "deploy", ["coffee", "deploy_contracts", "concat", "copy", "server", "watch"]
44
grunt.registerTask "build", ["clean", "deploy_contracts", "coffee", "concat", "uglify", "copy"]
5-
grunt.registerTask "release_ipfs", ["build", "ipfs"]
65

0 commit comments

Comments
 (0)