From 587d8142d253044685be7f8b3d9516171361dff0 Mon Sep 17 00:00:00 2001 From: holger krekel Date: Sun, 10 Dec 2023 12:17:05 +0100 Subject: [PATCH] some more housekeeping --- deploy-chatmail/pyproject.toml | 3 +++ deploy-chatmail/src/deploy_chatmail/cmdeploy.py | 15 ++++++--------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/deploy-chatmail/pyproject.toml b/deploy-chatmail/pyproject.toml index 7b6b243a..f2513971 100644 --- a/deploy-chatmail/pyproject.toml +++ b/deploy-chatmail/pyproject.toml @@ -19,6 +19,9 @@ dependencies = [ [project.scripts] cmdeploy = "deploy_chatmail.cmdeploy:main" +[tool.setuptools_scm] +write_to = "src/deploy_chatmail/_version.py" + [tool.pytest.ini_options] addopts = "-v -ra --strict-markers" diff --git a/deploy-chatmail/src/deploy_chatmail/cmdeploy.py b/deploy-chatmail/src/deploy_chatmail/cmdeploy.py index c0fd98f0..ee5340ad 100644 --- a/deploy-chatmail/src/deploy_chatmail/cmdeploy.py +++ b/deploy-chatmail/src/deploy_chatmail/cmdeploy.py @@ -51,7 +51,7 @@ def add_subcommand(subparsers, func): name = func.__name__ assert name.endswith("_cmd") name = name[:-4] - doc = func.__doc__.strip() + doc = func.__doc__.strip().strip(".") p = subparsers.add_parser(name, description=doc, help=doc) p.set_defaults(func=func) add_config_option(p) @@ -80,13 +80,10 @@ def get_parser(): help="don't actually modify the server", ) - add_subcommand(subparsers, webdev_cmd) - - add_subcommand(subparsers, test_cmd) - - add_subcommand(subparsers, bench_cmd) - add_subcommand(subparsers, dns_cmd) + add_subcommand(subparsers, bench_cmd) + add_subcommand(subparsers, test_cmd) + add_subcommand(subparsers, webdev_cmd) return parser @@ -116,7 +113,7 @@ def run_cmd(args, out, config): def webdev_cmd(args, out, config): - """Run web development loop for static local web pages.""" + """Run local web development loop for static web pages.""" from .www import main main() @@ -153,7 +150,7 @@ def read_dkim_entries(entry): def dns_cmd(args, out, config): - """generate dns zone file.""" + """Generate dns zone file.""" template = importlib.resources.files(__package__).joinpath("chatmail.zone.f") ssh = f"ssh root@{config.mailname}"