Print version in all scripts; add Updating section to README

This commit is contained in:
2026-06-19 19:04:48 +00:00
parent 5b9c888b72
commit c8de9971e7
6 changed files with 40 additions and 3 deletions
+3
View File
@@ -48,6 +48,8 @@ import sys
import urllib.error
import urllib.request
__version__ = "0.0.2"
_PATCH_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
_STATUS_FILE = os.path.join(_PATCH_DIR, "hook_status.json")
@@ -194,6 +196,7 @@ def main():
formatter_class=argparse.RawDescriptionHelpFormatter,
epilog=__doc__.split("Examples")[1] if __doc__ and "Examples" in __doc__ else "",
)
p.add_argument("--version", "-V", action="version", version=f"truecloud-patch {__version__}")
p.add_argument("--host", default=None, metavar="HOST",
help="TrueNAS hostname or IP address (required except for verify)")
p.add_argument("--api-key", default=None, metavar="KEY",