Skip to content

Commit

Permalink
cli: add -h as shortcut to --help
Browse files Browse the repository at this point in the history
  • Loading branch information
m1stadev committed Dec 27, 2023
1 parent 14e9c46 commit 16510e9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ Usage: pyimg4 [OPTIONS] COMMAND [ARGS]...
Options:
--version Show the version and exit.
--help Show this message and exit.
-h, --help Show this message and exit.
Commands:
im4m Image4 manifest commands.
Expand Down
4 changes: 3 additions & 1 deletion pyimg4/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,10 @@
import pyimg4
from pyimg4 import Compression, Keybag

CONTEXT_SETTINGS = dict(help_option_names=['-h', '--help'])

@click.group()

@click.group(context_settings=CONTEXT_SETTINGS)
@click.version_option(message=f'PyIMG4 {pyimg4.__version__}')
def cli():
"""A Python CLI tool for parsing Apple's Image4 format."""
Expand Down

0 comments on commit 16510e9

Please sign in to comment.