From 87752492d0dc7df3cf78011d5ce315a3eb0cad51 Mon Sep 17 00:00:00 2001 From: bndw Date: Fri, 23 Jan 2026 21:52:50 -0800 Subject: Restructure CLI with Cobra Replace custom switch-based routing with Cobra for cleaner command hierarchy. Reorganize commands into logical groups: - Root command handles deployment (--binary, --static, --domain, etc.) - App management at top level: list, logs, status, restart, remove - env subcommand group: list, set, unset - host subcommand group: init, status, update, ssh - Standalone: ui (renamed from webui), version Add version command with ldflags support for build info. --- cmd/deploy/host/host.go | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 cmd/deploy/host/host.go (limited to 'cmd/deploy/host/host.go') diff --git a/cmd/deploy/host/host.go b/cmd/deploy/host/host.go new file mode 100644 index 0000000..603a946 --- /dev/null +++ b/cmd/deploy/host/host.go @@ -0,0 +1,18 @@ +package host + +import ( + "github.com/spf13/cobra" +) + +var Cmd = &cobra.Command{ + Use: "host", + Short: "Manage VPS host", + Long: "Commands for managing and monitoring the VPS host", +} + +func init() { + Cmd.AddCommand(initCmd) + Cmd.AddCommand(statusCmd) + Cmd.AddCommand(updateCmd) + Cmd.AddCommand(sshCmd) +} -- cgit v1.2.3