|
1 | | -let program = require('commander'); |
2 | | -let colors = require('colors'); |
3 | | -let shelljs = require('shelljs'); |
4 | | -let promptly = require('promptly'); |
5 | | -let path = require('path'); |
| 1 | +const program = require('commander'); |
| 2 | +const promptly = require('promptly'); |
6 | 3 | const Embark = require('../lib/index'); |
7 | 4 | let embark = new Embark; |
8 | 5 |
|
@@ -30,11 +27,11 @@ class Cmd { |
30 | 27 | program.parse(args); |
31 | 28 | } |
32 | 29 |
|
33 | | - newApp(name) { |
| 30 | + newApp() { |
34 | 31 |
|
35 | 32 | let validateName = function (value) { |
36 | 33 | try { |
37 | | - if (value.match(/^[a-zA-Z\s\-]+$/)) return value; |
| 34 | + if (value.match(/^[a-zA-Z\s-]+$/)) return value; |
38 | 35 | } catch (e) { |
39 | 36 | throw new Error('Name must be only letters, spaces, or dashes'); |
40 | 37 | } |
@@ -79,7 +76,7 @@ class Cmd { |
79 | 76 | program |
80 | 77 | .command('build [environment]') |
81 | 78 | .description('deploy and build dapp at dist/ (default: development)') |
82 | | - .action(function (env, options) { |
| 79 | + .action(function (env, _options) { |
83 | 80 | embark.build({env: env || 'development'}); |
84 | 81 | }); |
85 | 82 | } |
@@ -150,7 +147,7 @@ class Cmd { |
150 | 147 | program |
151 | 148 | .command('upload [platform] [environment]') |
152 | 149 | .description('upload your dapp to a decentralized storage. possible options: ipfs, swarm (e.g embark upload swarm)') |
153 | | - .action(function (platform, env, options) { |
| 150 | + .action(function (platform, env, _options) { |
154 | 151 | // TODO: get env in cmd line as well |
155 | 152 | embark.initConfig(env || 'development', { |
156 | 153 | embarkConfig: 'embark.json', interceptLogs: false |
|
0 commit comments