Skip to content

Commit

Permalink
Make update and render subcommands non-eager
Browse files Browse the repository at this point in the history
  • Loading branch information
superatomic committed Sep 8, 2023
1 parent 7dfd557 commit b2503ce
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/tldr_man/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,13 +94,13 @@ def wrapper(*args: P.args, **kwargs: P.kwargs) -> T:
return wrapper


@subcommand('-u', '--update', is_eager=True)
@subcommand('-u', '--update')
def subcommand_update() -> None:
"""Update the tldr-pages cache"""
pages.update_cache()


@subcommand('-r', '--render', type=click.Path(exists=True, dir_okay=False, path_type=Path), is_eager=True)
@subcommand('-r', '--render', type=click.Path(exists=True, dir_okay=False, path_type=Path))
def subcommand_render(value: Path) -> None:
"""Render a page locally"""
page_to_render = value.read_text()
Expand Down

0 comments on commit b2503ce

Please sign in to comment.