Skip to content

Commit

Permalink
Add version cli
Browse files Browse the repository at this point in the history
  • Loading branch information
shun-liang committed Nov 10, 2024
1 parent dbc63fb commit b13ae85
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/yt2doc/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

from enum import Enum
from pathlib import Path
from importlib.metadata import version

import faster_whisper

Expand Down Expand Up @@ -102,7 +103,18 @@ def main(
help="Ignore original chapters from the source",
),
] = False,
show_version: typing.Annotated[
bool,
typer.Option(
"--version",
help="Show the current version of yt2doc",
),
] = False,
) -> None:
if show_version:
typer.echo(version("yt2doc"))
return

io_writer = IOWriter()

whisper_adapter: IWhisperAdapter
Expand Down

0 comments on commit b13ae85

Please sign in to comment.