From a0dc720a1e3a290b587bcdc2c9a1402eb0a05791 Mon Sep 17 00:00:00 2001 From: vxclutch Date: Wed, 24 Jun 2026 13:54:58 -0400 Subject: [PATCH] Add status and say to cobra --- main.go | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/main.go b/main.go index b42bf49..615044b 100644 --- a/main.go +++ b/main.go @@ -53,6 +53,19 @@ var shellCmd = &cobra.Command{ Args: cobra.ExactArgs(1), } +var sayCmd = &cobra.Command{ + Use: "say", + Short: "Say something in the server", + Run: server.Say, + Args: cobra.MinimumNArgs(1), +} + +var statusCMd = &cobra.Command{ + Use: "cmd", + Short: "Get the status of the server", + Run: server.Status, +} + //go:embed templates/docker-compose.yml var dockerCompose string @@ -73,6 +86,8 @@ func init() { rootCmd.AddCommand(stopCmd) rootCmd.AddCommand(restartCmd) rootCmd.AddCommand(shellCmd) + rootCmd.AddCommand(sayCmd) + rootCmd.AddCommand(statusCMd) t, err := template.New("compose").Parse(dockerCompose) if err != nil {