aboutsummaryrefslogtreecommitdiffstats
path: root/packages
diff options
context:
space:
mode:
Diffstat (limited to 'packages')
-rw-r--r--packages/deployer/src/cli.ts7
-rw-r--r--packages/deployer/src/compiler.ts2
2 files changed, 5 insertions, 4 deletions
diff --git a/packages/deployer/src/cli.ts b/packages/deployer/src/cli.ts
index b06168e31..5df9f9963 100644
--- a/packages/deployer/src/cli.ts
+++ b/packages/deployer/src/cli.ts
@@ -19,6 +19,7 @@ const DEFAULT_NETWORK_ID = 50;
const DEFAULT_JSONRPC_URL = 'http://localhost:8545';
const DEFAULT_GAS_PRICE = (10 ** 9 * 2).toString();
const DEFAULT_CONTRACTS_LIST = '*';
+const SEPARATOR = ',';
/**
* Compiles all contracts with options passed in through CLI.
@@ -28,7 +29,7 @@ async function onCompileCommandAsync(argv: CliOptions): Promise<void> {
const opts: CompilerOptions = {
contractsDir: argv.contractsDir,
artifactsDir: argv.artifactsDir,
- contracts: argv.contracts === '*' ? argv.contracts : argv.contracts.split(','),
+ contracts: argv.contracts === DEFAULT_CONTRACTS_LIST ? DEFAULT_CONTRACTS_LIST : argv.contracts.split(SEPARATOR),
};
await commands.compileAsync(opts);
}
@@ -44,7 +45,7 @@ async function onDeployCommandAsync(argv: CliOptions): Promise<void> {
const compilerOpts: CompilerOptions = {
contractsDir: argv.contractsDir,
artifactsDir: argv.artifactsDir,
- contracts: argv.contracts === '*' ? argv.contracts : argv.contracts.split(','),
+ contracts: argv.contracts === DEFAULT_CONTRACTS_LIST ? DEFAULT_CONTRACTS_LIST : argv.contracts.split(SEPARATOR),
};
await commands.compileAsync(compilerOpts);
@@ -59,7 +60,7 @@ async function onDeployCommandAsync(argv: CliOptions): Promise<void> {
defaults,
};
const deployerArgsString = argv.args as string;
- const deployerArgs = deployerArgsString.split(',');
+ const deployerArgs = deployerArgsString.split(SEPARATOR);
await commands.deployAsync(argv.contract as string, deployerArgs, deployerOpts);
}
/**
diff --git a/packages/deployer/src/compiler.ts b/packages/deployer/src/compiler.ts
index 673bc3186..85449ac8d 100644
--- a/packages/deployer/src/compiler.ts
+++ b/packages/deployer/src/compiler.ts
@@ -53,7 +53,7 @@ const DEFAULT_COMPILER_SETTINGS: solc.CompilerSettings = {
},
outputSelection: {
'*': {
- '*': ['abi', 'evm.bytecode.object'],
+ [ALL_CONTRACTS_IDENTIFIER]: ['abi', 'evm.bytecode.object'],
},
},
};