Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
f8e1d36
feat: init kitten completer
steschwa Feb 15, 2026
d5e853c
feat: at cmd
steschwa Feb 15, 2026
d239232
docs: subcommands todo
steschwa Feb 16, 2026
e0d55be
feat: update-self subcmd
steschwa Feb 16, 2026
91ff2d1
feat: edit-in-kitty subcmd
steschwa Feb 16, 2026
cc43b87
feat: clipboard subcmd
steschwa Feb 19, 2026
3c421f0
feat: icat subcmd
steschwa Feb 19, 2026
1814c8d
feat: ssh subcmd
steschwa Feb 19, 2026
ab4d5b2
feat: transfer subcmd
steschwa Feb 19, 2026
b2ce389
feat: transfer positional completions
steschwa Feb 19, 2026
9c6c3d0
feat: panel subcmd
steschwa Feb 19, 2026
409a753
feat: quick-access-terminal subcmd
steschwa Feb 19, 2026
c5a2ca8
feat: unicode-input subcmd
steschwa Feb 19, 2026
424407f
feat: show-key subcmd
steschwa Feb 19, 2026
8df9312
feat: wip desktop-ui subcmd
steschwa Feb 19, 2026
cc2c6a4
feat: mouse-demo subcmd
steschwa Feb 19, 2026
41e92de
feat: hyperlinked-grep subcmd
steschwa Feb 19, 2026
f0cc168
feat: ask subcmd
steschwa Feb 19, 2026
5924efd
feat: hints subcmd
steschwa Feb 19, 2026
8664886
feat: diff subcmd
steschwa Feb 19, 2026
a6c1ef1
feat: notify subcmd
steschwa Feb 20, 2026
065da60
feat: themes subcmd
steschwa Feb 20, 2026
f2d4881
feat: run-shell subcmd
steschwa Feb 20, 2026
9d7f316
feat: choose-fonts subcmd
steschwa Feb 20, 2026
f78cc10
feat: choose-files subcmd
steschwa Feb 20, 2026
cf053c3
feat: query-terminal subcmd
steschwa Feb 20, 2026
13a05ef
feat: wip @ subcmds
steschwa Feb 20, 2026
9452bf1
feat: wip @ subcmds stubs
steschwa Feb 20, 2026
6985147
docs: cleanup
steschwa Feb 20, 2026
4770ae0
chore: move
steschwa Feb 20, 2026
e3e9b11
fix: update package
steschwa Feb 20, 2026
aa4d4ab
feat: wip kitty actions completion
steschwa Feb 20, 2026
e538e51
fix: unused imports
steschwa Feb 20, 2026
f5f541e
feat: wip at cmd completions
steschwa Feb 20, 2026
d53e15c
feat: wip at cmd completions
steschwa Feb 20, 2026
8f689b1
style: flags order
steschwa Feb 20, 2026
a079024
style: flags order
steschwa Feb 20, 2026
f91d2be
docs: check
steschwa Feb 20, 2026
b4078c2
feat: desktop-ui subcmd completers
steschwa Feb 20, 2026
7819dc0
docs: cleanup
steschwa Feb 20, 2026
75b5f45
chore: cleanup comments
steschwa Feb 20, 2026
d33b748
style: format
steschwa Feb 20, 2026
6e8d9b3
kitten: moved action
rsteube Feb 21, 2026
e62785e
fix: invert addCommand
steschwa Feb 23, 2026
f4bafdc
fix subcommand completion and align style
rsteube Feb 26, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions completers/common/kitten_completer/cmd/ask.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/spf13/cobra"
)

var askCmd = &cobra.Command{
Use: "ask",
Short: "Ask the user for input",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(askCmd).Standalone()

askCmd.Flags().StringP("choice", "c", "", "A choice for the choices type. Can be specified multiple times. Every choice has the syntax: ``letter[;color]:text``, where text is the choice text and letter is the selection key. letter is a single letter belonging to text. This letter is highlighted within the choice text. There can be an optional color specification after the letter to indicate what color it should be. For example: y:Yes and n;red:No")
askCmd.Flags().StringP("default", "d", "", "A default choice or text. If unspecified, it is y for the type yesno, the first choice for choices and empty for others types. The default choice is selected when the user presses the Enter key.")
askCmd.Flags().BoolP("help", "h", false, "Show help for this command")
askCmd.Flags().String("hidden-text-placeholder", "", "The text in the message to be replaced by hidden text. The hidden text is read via STDIN.")
askCmd.Flags().StringP("message", "m", "", "The message to display to the user. If not specified a default message is shown.")
askCmd.Flags().StringP("name", "n", "", "The name for this question. Used to store history of previous answers which can be used for completions and via the browse history readline bindings.")
askCmd.Flags().StringP("prompt", "p", "", "The prompt to use when inputting a line of text or a password.")
askCmd.Flags().String("title", "", "The title for the window in which the question is displayed. Only implemented for yesno and choices types.")
askCmd.Flags().StringP("type", "t", "", "Type of input. Defaults to asking for a line of text.")
askCmd.Flags().String("unhide-key", "", "The key to be pressed to unhide hidden text")
askCmd.Flags().String("window-title", "", "The title for the window in which the question is displayed. Only implemented for yesno and choices types.")
rootCmd.AddCommand(askCmd)

carapace.Gen(askCmd).FlagCompletion(carapace.ActionMap{
"type": carapace.ActionValues("line", "choices", "file", "password", "yesno"),
})
}
37 changes: 37 additions & 0 deletions completers/common/kitten_completer/cmd/at.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/carapace-sh/carapace-bin/pkg/actions/os"
"github.com/spf13/cobra"
)

var atCmd = &cobra.Command{
Use: "@",
Short: "Control kitty remotely",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(atCmd).Standalone()

atCmd.Flags().BoolP("help", "h", false, "Show help for this command")
atCmd.Flags().String("password", "", "A password to use when contacting kitty. This will cause kitty to ask the user for permission to perform the specified action, unless the password has been accepted before or is pre-configured in kitty.conf. To use a blank password specify --use-password as always.")
atCmd.Flags().String("password-env", "", "The name of an environment variable to read the password from. Used if no --password-file is supplied. Defaults to checking the environment variable KITTY_RC_PASSWORD.")
atCmd.Flags().String("password-file", "", "A password to use when contacting kitty. This will cause kitty to ask the user for permission to perform the specified action, unless the password has been accepted before or is pre-configured in kitty.conf. To use a blank password specify --use-password as always.")
atCmd.Flags().String("to", "", "An address for the kitty instance to control. Corresponds to the address given to the kitty instance via the --listen-on option or the listen_on setting in kitty.conf. If not specified, the environment variable KITTY_LISTEN_ON is checked. If that is also not found, messages are sent to the controlling terminal for this process, i.e. they will only work if this process is run within a kitty window.")
atCmd.Flags().String("use-password", "", "If no password is available, kitty will usually just send the remote control command without a password. This option can be used to force it to always or never use the supplied password. If set to always and no password is provided, the blank password is used.")
rootCmd.AddCommand(atCmd)

atCmd.MarkFlagsMutuallyExclusive("password-file", "password-env")

carapace.Gen(atCmd).FlagCompletion(carapace.ActionMap{
"password-env": os.ActionEnvironmentVariables(),
"password-file": carapace.Batch(
carapace.ActionFiles(),
carapace.ActionValuesDescribed("-", "Read from STDIN"),
carapace.ActionValuesDescribed("fd:", "Read from a file descriptor").NoSpace(':'),
).ToA(),
"use-password": carapace.ActionValues("if-available", "always", "never"),
})
}
27 changes: 27 additions & 0 deletions completers/common/kitten_completer/cmd/at_action.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/carapace-sh/carapace-bin/pkg/actions/tools/kitty"
"github.com/spf13/cobra"
)

var at_actionCmd = &cobra.Command{
Use: "action",
Short: "Run the specified mappable action",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(at_actionCmd).Standalone()

at_actionCmd.Flags().BoolP("help", "h", false, "Show help for this command")
at_actionCmd.Flags().StringP("match", "m", "", "The window to match")
at_actionCmd.Flags().Bool("no-response", false, "Don't wait for a response indicating the success of the action")
at_actionCmd.Flags().Bool("self", false, "Run the action on the window this command is run in instead of the active window")
atCmd.AddCommand(at_actionCmd)

carapace.Gen(at_actionCmd).PositionalAnyCompletion(
kitty.ActionActions(),
)
}
24 changes: 24 additions & 0 deletions completers/common/kitten_completer/cmd/at_closeTab.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/spf13/cobra"
)

var at_closeTabCmd = &cobra.Command{
Use: "close-tab",
Short: "Close the specified tabs",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(at_closeTabCmd).Standalone()

at_closeTabCmd.Flags().BoolP("help", "h", false, "Show help for this command")
at_closeTabCmd.Flags().Bool("ignore-no-match", false, "Do not return an error if no tabs are matched to be closed")
at_closeTabCmd.Flags().StringP("match", "m", "", "The tab to match")
at_closeTabCmd.Flags().Bool("no-response", false, "Don't wait for a response indicating the success of the action")
at_closeTabCmd.Flags().Bool("self", false, "Close the tab of the window this command is run in, rather than the active tab")
atCmd.AddCommand(at_closeTabCmd)

}
24 changes: 24 additions & 0 deletions completers/common/kitten_completer/cmd/at_closeWindow.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/spf13/cobra"
)

var at_closeWindowCmd = &cobra.Command{
Use: "close-window",
Short: "Close the specified windows",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(at_closeWindowCmd).Standalone()

at_closeWindowCmd.Flags().BoolP("help", "h", false, "Show help for this command")
at_closeWindowCmd.Flags().Bool("ignore-no-match", false, "Do not return an error if no windows are matched to be closed")
at_closeWindowCmd.Flags().StringP("match", "m", "", "The window to match")
at_closeWindowCmd.Flags().Bool("no-response", false, "Don't wait for a response indicating the success of the action")
at_closeWindowCmd.Flags().Bool("self", false, "Close the window this command is run in, rather than the active window")
atCmd.AddCommand(at_closeWindowCmd)

}
22 changes: 22 additions & 0 deletions completers/common/kitten_completer/cmd/at_createMarker.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/spf13/cobra"
)

var at_createMarkerCmd = &cobra.Command{
Use: "create-marker",
Short: "Create a marker that highlights specified text",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(at_createMarkerCmd).Standalone()

at_createMarkerCmd.Flags().BoolP("help", "h", false, "Show help for this command")
at_createMarkerCmd.Flags().StringP("match", "m", "", "The window to match")
at_createMarkerCmd.Flags().Bool("self", false, "Apply marker to the window this command is run in, rather than the active window")
atCmd.AddCommand(at_createMarkerCmd)

}
23 changes: 23 additions & 0 deletions completers/common/kitten_completer/cmd/at_detachTab.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/spf13/cobra"
)

var at_detachTabCmd = &cobra.Command{
Use: "detach-tab",
Short: "Detach the specified tabs and place them in a different/new OS window",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(at_detachTabCmd).Standalone()

at_detachTabCmd.Flags().BoolP("help", "h", false, "Show help for this command")
at_detachTabCmd.Flags().StringP("match", "m", "", "The tab to match")
at_detachTabCmd.Flags().Bool("self", false, "Detach the tab this command is run in, rather than the active tab")
at_detachTabCmd.Flags().StringP("target-tab", "t", "", "The tab to match")
atCmd.AddCommand(at_detachTabCmd)

}
24 changes: 24 additions & 0 deletions completers/common/kitten_completer/cmd/at_detachWindow.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/spf13/cobra"
)

var at_detachWindowCmd = &cobra.Command{
Use: "detach-window",
Short: "Detach the specified windows and place them in a different/new tab",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(at_detachWindowCmd).Standalone()

at_detachWindowCmd.Flags().BoolP("help", "h", false, "Show help for this command")
at_detachWindowCmd.Flags().StringP("match", "m", "", "The window to match")
at_detachWindowCmd.Flags().Bool("self", false, "Detach the window this command is run in, rather than the active window")
at_detachWindowCmd.Flags().Bool("stay-in-tab", false, "Keep the focus on a window in the currently focused tab after moving the specified windows")
at_detachWindowCmd.Flags().StringP("target-tab", "t", "", "The tab to match")
atCmd.AddCommand(at_detachWindowCmd)

}
23 changes: 23 additions & 0 deletions completers/common/kitten_completer/cmd/at_disableLigatures.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/spf13/cobra"
)

var at_disableLigaturesCmd = &cobra.Command{
Use: "disable-ligatures",
Short: "Control ligature rendering",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(at_disableLigaturesCmd).Standalone()

at_disableLigaturesCmd.Flags().BoolP("all", "a", false, "By default, ligatures are only affected in the active window")
at_disableLigaturesCmd.Flags().BoolP("help", "h", false, "Show help for this command")
at_disableLigaturesCmd.Flags().StringP("match", "m", "", "The window to match")
at_disableLigaturesCmd.Flags().StringP("match-tab", "t", "", "The tab to match")
atCmd.AddCommand(at_disableLigaturesCmd)

}
20 changes: 20 additions & 0 deletions completers/common/kitten_completer/cmd/at_env.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/spf13/cobra"
)

var at_envCmd = &cobra.Command{
Use: "env",
Short: "Change environment variables seen by future children",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(at_envCmd).Standalone()

at_envCmd.Flags().BoolP("help", "h", false, "Show help for this command")
atCmd.AddCommand(at_envCmd)

}
22 changes: 22 additions & 0 deletions completers/common/kitten_completer/cmd/at_focusTab.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/spf13/cobra"
)

var at_focusTabCmd = &cobra.Command{
Use: "focus-tab",
Short: "Focus the specified tab",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(at_focusTabCmd).Standalone()

at_focusTabCmd.Flags().BoolP("help", "h", false, "Show help for this command")
at_focusTabCmd.Flags().StringP("match", "m", "", "The tab to match")
at_focusTabCmd.Flags().Bool("no-response", false, "Don't wait for a response indicating the success of the action")
atCmd.AddCommand(at_focusTabCmd)

}
22 changes: 22 additions & 0 deletions completers/common/kitten_completer/cmd/at_focusWindow.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/spf13/cobra"
)

var at_focusWindowCmd = &cobra.Command{
Use: "focus-window",
Short: "Focus the specified window",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(at_focusWindowCmd).Standalone()

at_focusWindowCmd.Flags().BoolP("help", "h", false, "Show help for this command")
at_focusWindowCmd.Flags().StringP("match", "m", "", "The window to match")
at_focusWindowCmd.Flags().Bool("no-response", false, "Don't wait for a response from kitty")
atCmd.AddCommand(at_focusWindowCmd)

}
22 changes: 22 additions & 0 deletions completers/common/kitten_completer/cmd/at_getColors.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/spf13/cobra"
)

var at_getColorsCmd = &cobra.Command{
Use: "get-colors",
Short: "Get terminal colors",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(at_getColorsCmd).Standalone()

at_getColorsCmd.Flags().BoolP("configured", "c", false, "Instead of outputting the colors for the specified window, output the currently configured colors")
at_getColorsCmd.Flags().BoolP("help", "h", false, "Show help for this command")
at_getColorsCmd.Flags().StringP("match", "m", "", "The window to match")
atCmd.AddCommand(at_getColorsCmd)

}
30 changes: 30 additions & 0 deletions completers/common/kitten_completer/cmd/at_getText.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/spf13/cobra"
)

var at_getTextCmd = &cobra.Command{
Use: "get-text",
Short: "Get text from the specified window",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(at_getTextCmd).Standalone()

at_getTextCmd.Flags().Bool("add-cursor", false, "Add ANSI escape codes specifying the cursor position and style to the end of the text")
at_getTextCmd.Flags().Bool("add-wrap-markers", false, "Add carriage returns at every line wrap location")
at_getTextCmd.Flags().Bool("ansi", false, "Include the ANSI formatting escape codes for colors, bold, italic, etc.")
at_getTextCmd.Flags().Bool("clear-selection", false, "Clear the selection in the matched window, if any")
at_getTextCmd.Flags().String("extent", "screen", "What text to get")
at_getTextCmd.Flags().BoolP("help", "h", false, "Show help for this command")
at_getTextCmd.Flags().StringP("match", "m", "", "The window to match")
at_getTextCmd.Flags().Bool("self", false, "Get text from the window this command is run in, rather than the active window")
atCmd.AddCommand(at_getTextCmd)

carapace.Gen(at_getTextCmd).FlagCompletion(carapace.ActionMap{
"extent": carapace.ActionValues("screen", "all", "first_cmd_output_on_screen", "last_cmd_output", "last_non_empty_output", "last_visited_cmd_output", "selection"),
})
}
20 changes: 20 additions & 0 deletions completers/common/kitten_completer/cmd/at_gotoLayout.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
package cmd

import (
"github.com/carapace-sh/carapace"
"github.com/spf13/cobra"
)

var at_gotoLayoutCmd = &cobra.Command{
Use: "goto-layout",
Short: "Set the window layout",
Run: func(cmd *cobra.Command, args []string) {},
}

func init() {
carapace.Gen(at_gotoLayoutCmd).Standalone()

at_gotoLayoutCmd.Flags().BoolP("help", "h", false, "Show help for this command")
at_gotoLayoutCmd.Flags().StringP("match", "m", "", "The tab to match")
atCmd.AddCommand(at_gotoLayoutCmd)
}
Loading