Add some basic RC serialization tests

This commit is contained in:
Kovid Goyal
2022-08-17 08:40:57 +05:30
parent 4432c1a2ea
commit 33e16df586
7 changed files with 169 additions and 37 deletions

View File

@@ -8,13 +8,24 @@ import (
"github.com/spf13/cobra"
"kitty/tools/cli"
"kitty/tools/utils"
)
func run_CMD_NAME(cmd *cobra.Command, args []string) (err error) {
rc := utils.RemoteControlCmd{
Cmd: "CLI_NAME",
Version: [3]int{0, 20, 0},
}
err = send_rc_command(&rc)
return
}
func setup_CMD_NAME(root *cobra.Command) *cobra.Command {
ans := cli.CreateCommand(&cobra.Command{
Use: "CLI_NAME [options]",
Short: "SHORT_DESC",
Long: "LONG_DESC",
RunE: run_CMD_NAME,
})
return ans