@@ -25,5 +25,6 @@ func NewRootCommand(version string) *cobra.Command {
|
||||
addAlertCmd(root)
|
||||
addTrustCmd(root)
|
||||
addStatusCmd(root)
|
||||
addTUICmd(root)
|
||||
return root
|
||||
}
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
package cli
|
||||
|
||||
import (
|
||||
"github.com/spf13/cobra"
|
||||
|
||||
"git.cer.sh/axodouble/quptime/internal/tui"
|
||||
)
|
||||
|
||||
func addTUICmd(root *cobra.Command) {
|
||||
cmd := &cobra.Command{
|
||||
Use: "tui",
|
||||
Short: "Open the interactive terminal UI",
|
||||
Long: "Open a full-screen TUI that overlays the same commands the CLI offers.\n" +
|
||||
"The TUI is a thin client over the local daemon socket — start the daemon\n" +
|
||||
"with `qu serve` before running this.",
|
||||
RunE: func(cmd *cobra.Command, args []string) error {
|
||||
return tui.Run()
|
||||
},
|
||||
}
|
||||
root.AddCommand(cmd)
|
||||
}
|
||||
Reference in New Issue
Block a user