diff --git a/completers/wezterm_completer/cmd/cli_getText.go b/completers/wezterm_completer/cmd/cli_getText.go new file mode 100644 index 0000000000..5eb9ba4450 --- /dev/null +++ b/completers/wezterm_completer/cmd/cli_getText.go @@ -0,0 +1,28 @@ +package cmd + +import ( + "github.com/rsteube/carapace" + "github.com/rsteube/carapace-bin/pkg/actions/tools/wezterm" + "github.com/spf13/cobra" +) + +var cli_getTextCmd = &cobra.Command{ + Use: "get-text", + Short: "Retrieves the textual content of a pane and output it to stdout", + Run: func(cmd *cobra.Command, args []string) {}, +} + +func init() { + carapace.Gen(cli_getTextCmd).Standalone() + + cli_getTextCmd.Flags().String("end-line", "", "The ending line number") + cli_getTextCmd.Flags().Bool("escapes", false, "Include escape sequences that color and style the text") + cli_getTextCmd.Flags().BoolP("help", "h", false, "Print help") + cli_getTextCmd.Flags().String("pane-id", "", "Specify the target pane") + cli_getTextCmd.Flags().String("start-line", "", "The starting line number") + cliCmd.AddCommand(cli_getTextCmd) + + carapace.Gen(cli_getTextCmd).FlagCompletion(carapace.ActionMap{ + "pane-id": wezterm.ActionPanes(), + }) +} diff --git a/completers/wezterm_completer/cmd/cli_sendText.go b/completers/wezterm_completer/cmd/cli_sendText.go new file mode 100644 index 0000000000..e4bbf1f4fc --- /dev/null +++ b/completers/wezterm_completer/cmd/cli_sendText.go @@ -0,0 +1,26 @@ +package cmd + +import ( + "github.com/rsteube/carapace" + "github.com/rsteube/carapace-bin/pkg/actions/tools/wezterm" + "github.com/spf13/cobra" +) + +var cli_sendTextCmd = &cobra.Command{ + Use: "send-text", + Short: "Send text to a pane as though it were pasted", + Run: func(cmd *cobra.Command, args []string) {}, +} + +func init() { + carapace.Gen(cli_sendTextCmd).Standalone() + + cli_sendTextCmd.Flags().BoolP("help", "h", false, "Print help") + cli_sendTextCmd.Flags().Bool("no-paste", false, "Send the text directly, rather than as a bracketed paste") + cli_sendTextCmd.Flags().String("pane-id", "", "Specify the target pane") + cliCmd.AddCommand(cli_sendTextCmd) + + carapace.Gen(cli_sendTextCmd).FlagCompletion(carapace.ActionMap{ + "pane-id": wezterm.ActionPanes(), + }) +}