mirror of
https://github.com/esphome/esphome.git
synced 2024-12-22 16:37:52 +01:00
Add `--version
` handler to cli (#7150)
This commit is contained in:
parent
39c0019534
commit
adfec578cf
@ -747,7 +747,14 @@ def parse_args(argv):
|
||||
)
|
||||
|
||||
parser = argparse.ArgumentParser(
|
||||
description=f"ESPHome v{const.__version__}", parents=[options_parser]
|
||||
description=f"ESPHome {const.__version__}", parents=[options_parser]
|
||||
)
|
||||
|
||||
parser.add_argument(
|
||||
"--version",
|
||||
action="version",
|
||||
version=f"Version: {const.__version__}",
|
||||
help="Print the ESPHome version and exit.",
|
||||
)
|
||||
|
||||
mqtt_options = argparse.ArgumentParser(add_help=False)
|
||||
|
Loading…
Reference in New Issue
Block a user