Skip to content

Commit

Permalink
fix: fix options
Browse files Browse the repository at this point in the history
  • Loading branch information
adnpark committed Mar 7, 2024
1 parent d4a7f8d commit 6372352
Showing 1 changed file with 16 additions and 14 deletions.
30 changes: 16 additions & 14 deletions src/command/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,10 +127,7 @@ program
.option("-t, --testnet-all", "select all testnets", false)
.option("-m, --mainnet-all", "select all mainnets", false)
.option("-a, --all-networks", "select all networks", false)
.option(
"-c, --chains [CHAINS]",
"list of chains for deploying contracts, defaults to all testnets"
)
.option("-c, --chains [CHAINS]", "list of chains for deploying contracts")
.option("-e, --expected-address [ADDRESS]", "expected address to confirm")
.option(
"-v, --verify-contract [CONTRACT_NAME]",
Expand Down Expand Up @@ -195,22 +192,27 @@ program
"-s, --salt <salt>",
"salt to be used for CREATE2. This can be a full 32-byte hex string or a shorter numeric representation that will be converted to a 32-byte hex string."
)
.option(
"-c, --chains [CHAINS]",
"list of chains to check, with all selected by default",
"all"
)

.option("-t, --testnet-all", "check all testnets", false)
.option("-m, --mainnet-all", "check all mainnets", false)
.option("-t, --testnet-all", "select all testnets", false)
.option("-m, --mainnet-all", "select all mainnets", false)
.option("-a, --all-networks", "select all networks", false)
.option("-c, --chains [CHAINS]", "list of chains for checking")
.action(async (options) => {
const { file, bytecode, salt, chains, testnetAll, mainnetAll } = options
const {
file,
bytecode,
salt,
testnetAll,
mainnetAll,
allNetworks,
chains
} = options

const normalizedSalt = normalizeSalt(salt)
validateInputs(file, bytecode, normalizedSalt, undefined)
const chainObjects = processAndValidateChains(chains, {
testnetAll,
mainnetAll
mainnetAll,
allNetworks
})

let bytecodeToDeploy = bytecode
Expand Down

0 comments on commit 6372352

Please sign in to comment.