Skip to content

Commit

Permalink
cli: Add --version
Browse files Browse the repository at this point in the history
  • Loading branch information
avdgrinten committed Nov 10, 2024
1 parent d0bab40 commit 7589bae
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions xbstrap/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
# SPDX-License-Identifier: MIT

import argparse
import importlib.metadata
import json
import os
import random
Expand All @@ -25,6 +26,9 @@

main_parser = argparse.ArgumentParser()
main_parser.add_argument("-v", dest="verbose", action="store_true", help="verbose")
main_parser.add_argument(
"--version", action="version", version=importlib.metadata.version("xbstrap")
)
main_parser.add_argument(
"--debug-cfg-files",
action="store_true",
Expand Down

0 comments on commit 7589bae

Please sign in to comment.