feat(cli): add upgrade alias and register mail command

- Add upgrade as an alias for update
- Register mail_cmd in CLI entrypoint
This commit is contained in:
Zhengshou Lai
2026-04-17 00:02:46 +08:00
parent 2618f626a7
commit afc81dcd84
2 changed files with 8 additions and 2 deletions
+3 -1
View File
@@ -4,7 +4,7 @@ from importlib.metadata import PackageNotFoundError, version
import click
from myclaude.commands import chat_cmd, update_cmd
from myclaude.commands import chat_cmd, mail_cmd, update_cmd, upgrade_cmd
def _package_version() -> str:
@@ -21,7 +21,9 @@ def cli() -> None:
cli.add_command(update_cmd)
cli.add_command(upgrade_cmd, name="upgrade")
cli.add_command(chat_cmd)
cli.add_command(mail_cmd)
def main() -> None:
+5 -1
View File
@@ -1,6 +1,10 @@
"""CLI subcommands."""
from .chat import chat_cmd
from .mail import mail_cmd
from .update import update_cmd
__all__ = ["chat_cmd", "update_cmd"]
# alias: upgrade is the same as update
upgrade_cmd = update_cmd
__all__ = ["chat_cmd", "mail_cmd", "update_cmd", "upgrade_cmd"]