From 49791c916a722daae020dc034130dc5e92606cd3 Mon Sep 17 00:00:00 2001 From: Iuri Matias Date: Wed, 25 Jul 2018 09:29:18 -0400 Subject: [PATCH] simplify: mv reset code into index --- lib/cmds/reset.js | 8 -------- lib/index.js | 8 +++++--- 2 files changed, 5 insertions(+), 11 deletions(-) delete mode 100644 lib/cmds/reset.js diff --git a/lib/cmds/reset.js b/lib/cmds/reset.js deleted file mode 100644 index 557e7b67f..000000000 --- a/lib/cmds/reset.js +++ /dev/null @@ -1,8 +0,0 @@ -var fs = require('../core/fs.js'); - -module.exports = function() { - fs.removeSync('./chains.json'); - fs.removeSync('.embark/'); - fs.removeSync('dist/'); - console.log(__("reset done!").green); -}; diff --git a/lib/index.js b/lib/index.js index 92d2aad24..8d0d75ba7 100644 --- a/lib/index.js +++ b/lib/index.js @@ -354,9 +354,11 @@ class Embark { } reset() { - this.context = [constants.contexts.reset]; - let resetCmd = require('./cmds/reset.js'); - resetCmd(); + var fs = require('../core/fs.js'); + fs.removeSync('./chains.json'); + fs.removeSync('.embark/'); + fs.removeSync('dist/'); + console.log(__("reset done!").green); } upload(options) {