-
-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
54 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -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(), | ||
}) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -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(), | ||
}) | ||
} |