Skip to content

Commit 28ce1e7

Browse files
authored
Merge pull request #323 from crytic/dev-fix-foundry-options
Add missing command-line arguments
2 parents 8172da5 + cb067dd commit 28ce1e7

File tree

1 file changed

+13
-11
lines changed

1 file changed

+13
-11
lines changed

crytic_compile/cryticparser/cryticparser.py

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -16,33 +16,33 @@ def init(parser: ArgumentParser) -> None:
1616
parser (ArgumentParser): argparser where the cli flags are added
1717
"""
1818

19-
group_solc = parser.add_argument_group("Compile options")
19+
group_compile = parser.add_argument_group("Compile options")
2020

2121
platforms = get_platforms()
2222

23-
group_solc.add_argument(
23+
group_compile.add_argument(
2424
"--compile-force-framework",
2525
help="Force the compile to a given framework "
2626
f"({','.join([x.NAME.lower() for x in platforms])})",
2727
action="store",
2828
default=DEFAULTS_FLAG_IN_CONFIG["compile_force_framework"],
2929
)
3030

31-
group_solc.add_argument(
31+
group_compile.add_argument(
3232
"--compile-remove-metadata",
3333
help="Remove the metadata from the bytecodes",
3434
action="store_true",
3535
default=DEFAULTS_FLAG_IN_CONFIG["compile_remove_metadata"],
3636
)
3737

38-
group_solc.add_argument(
38+
group_compile.add_argument(
3939
"--compile-custom-build",
4040
help="Replace platform specific build command",
4141
action="store",
4242
default=DEFAULTS_FLAG_IN_CONFIG["compile_custom_build"],
4343
)
4444

45-
group_solc.add_argument(
45+
group_compile.add_argument(
4646
"--ignore-compile",
4747
help="Do not run compile of any platform",
4848
action="store_true",
@@ -53,13 +53,15 @@ def init(parser: ArgumentParser) -> None:
5353
_init_solc(parser)
5454
_init_truffle(parser)
5555
_init_embark(parser)
56+
_init_brownie(parser)
5657
_init_dapp(parser)
5758
_init_etherlime(parser)
5859
_init_etherscan(parser)
5960
_init_waffle(parser)
6061
_init_npx(parser)
6162
_init_buidler(parser)
6263
_init_hardhat(parser)
64+
_init_foundry(parser)
6365

6466

6567
def _init_solc(parser: ArgumentParser) -> None:
@@ -230,8 +232,8 @@ def _init_brownie(parser: ArgumentParser) -> None:
230232
Args:
231233
parser (ArgumentParser): argparser where the cli flags are added
232234
"""
233-
group_embark = parser.add_argument_group("Brownie options")
234-
group_embark.add_argument(
235+
group_brownie = parser.add_argument_group("Brownie options")
236+
group_brownie.add_argument(
235237
"--brownie-ignore-compile",
236238
help="Do not run brownie compile",
237239
action="store_true",
@@ -431,7 +433,7 @@ def _init_hardhat(parser: ArgumentParser) -> None:
431433
Args:
432434
parser (ArgumentParser): argparser where the cli flags are added
433435
"""
434-
group_hardhat = parser.add_argument_group("hardhat options")
436+
group_hardhat = parser.add_argument_group("Hardhat options")
435437
group_hardhat.add_argument(
436438
"--hardhat-ignore-compile",
437439
help="Do not run hardhat compile",
@@ -463,16 +465,16 @@ def _init_foundry(parser: ArgumentParser) -> None:
463465
Args:
464466
parser (ArgumentParser): argparser where the cli flags are added
465467
"""
466-
group_hardhat = parser.add_argument_group("foundry options")
467-
group_hardhat.add_argument(
468+
group_foundry = parser.add_argument_group("Foundry options")
469+
group_foundry.add_argument(
468470
"--foundry-ignore-compile",
469471
help="Do not run foundry compile",
470472
action="store_true",
471473
dest="foundry_ignore_compile",
472474
default=DEFAULTS_FLAG_IN_CONFIG["foundry_ignore_compile"],
473475
)
474476

475-
group_hardhat.add_argument(
477+
group_foundry.add_argument(
476478
"--foundry-out-directory",
477479
help="Use an alternative out directory (default: out)",
478480
action="store",

0 commit comments

Comments
 (0)