Skip to content

Commit 1e278c5

Browse files
committed
feat(CLI)!: remove help command as no_args_is_help is true
1 parent 4b220b7 commit 1e278c5

3 files changed

Lines changed: 5 additions & 2 deletions

File tree

codesectools/cli.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
cli = typer.Typer(
3535
name=CLI_NAME,
3636
no_args_is_help=True,
37+
add_help_option=False,
3738
add_completion=not any(f.is_file() for f in COMPLETION_FILE),
3839
)
3940

codesectools/sasts/all/cli.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
def build_cli() -> typer.Typer:
2020
"""Build the Typer CLI for running all SAST tools."""
21-
cli = typer.Typer(name="allsast", no_args_is_help=True)
21+
cli = typer.Typer(name="allsast", no_args_is_help=True, add_help_option=False)
2222
all_sast = AllSAST()
2323

2424
@cli.callback()

codesectools/sasts/core/cli.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,9 @@ def __init__(self, sast: SAST, custom_messages: dict) -> None:
5151

5252
def build_cli(self) -> typer.Typer:
5353
"""Build and return the Typer CLI application for the SAST tool."""
54-
self.cli = typer.Typer(name=self.sast.name.lower(), no_args_is_help=True)
54+
self.cli = typer.Typer(
55+
name=self.sast.name.lower(), no_args_is_help=True, add_help_option=False
56+
)
5557
self._add_minimal()
5658
return self.cli
5759

0 commit comments

Comments
 (0)