kitten-@-detach-tab(1)
π kitten-@-detach-tab β the manual page, bestie edition
okay so you're reading kitten-@-detach-tab, which lives in the kitten Manual (section 1, if we're being official about it). It's a little remote-control kitten that β¨yeetsβ¨ your tabs into another window. Let's get into it.
πΈ NAME
kitten-@-detach-tab β detach the tabs you specify and place them in a different slash new OS window. that's it, that's the whole vibe. π
π«Ά USAGE
kitten @ detach-tab
π¦ DESCRIPTION
So basically: you point at some tabs, and this kitten detaches them and either moves them into a brand new OS window or adds them to the OS window that contains the tab you named with --target-tab. pick your fighter. β¨
π OPTIONS
--match,-mβ the tab to match. ngl, this is the big one, so let's break it down.
Match specifications look like field:query, where field can be one of: id, index, title, window_id, window_title, pid, cwd, cmdline, env, var, state, session and recent. and query is the expression you're matching on. expressions can be either a number or a regular expression, and β plot twist β you can combine them using Boolean operators. π₯
The special value all matches all tabs. every. single. one. π
For the numeric fields β id, index, window_id, pid and recent β the expression is interpreted as a number, not a regular expression. Negative values for id/window_id match from the highest id number down; in particular, -1 is the most recently created tab/window. so -1 is giving main character energy, obviously. π
When you use title or id, first a matching tab is looked for, and if it's not found, a matching window is looked for, and the tab for that window is used. it's giving backup plan. π«Ά
You can also use window_id and window_title to match the tab that contains the window with the specified id or title.
The index number matches the nth tab in the currently active OS window. The recent number matches recently active tabs in the currently active OS window, with zero being the currently active tab, one the previously active tab, and so on. counting from zero, because of course. π
The session field matches tabs that were created in the specified session. Use the expression ^$ to match windows that were not created in a session, . to match the currently active session, and ~ to match either the currently active session or the last active session when no session is active. cute little symbols, huge power. β
When you use the env field to match on environment variables, you can specify just the environment variable name, or a name and value β for example, env:MY_ENV_VAR=2. Tabs containing any window with the specified environment variables are matched. Similarly, var matches tabs containing any window with the specified user variable. π
The state field matches on the state of the tab. supported states are: active, focused, needs_attention, parent_active, parent_focused and focused_os_window. Active tabs are the tabs that are active in their parent OS window. There is only one focused tab, and it's the tab that keyboard events get delivered to. If no tab is focused, the last focused tab is matched. The value focused_os_window matches all tabs in the currently focused OS window. iykyk. π
pro tip from the manpage itself: you can use the kitten @ ls command to get a list of tabs. go look at your tabs, bestie. π
--target-tab,-tβ the tab to match. yes, same flavour of match spec, so buckle up again, bestie.
Match specifications are of the form field:query. The field can be one of: id, index, title, window_id, window_title, pid, cwd, cmdline, env, var, state, session and recent. The query is the expression to match. Expressions can be either a number or a regular expression, and can be combined using Boolean operators. β¨
The special value all matches all tabs. all of them. no notes. π
For numeric fields: id, index, window_id, pid and recent, the expression is interpreted as a number, not a regular expression. Negative values for id/window_id match from the highest id number down, in particular, -1 is the most recently created tab/window. yes we're saying it again, it's important. π
When using title or id, first a matching tab is looked for, and if not found a matching window is looked for, and the tab for that window is used.
You can also use window_id and window_title to match the tab that contains the window with the specified id or title. π
The index number is used to match the nth tab in the currently active OS window. The recent number matches recently active tabs in the currently active OS window, with zero being the currently active tab, one the previously active tab and so on.
The field session matches tabs that were created in the specified session. Use the expression ^$ to match windows that were not created in a session, . to match the currently active session, and ~ to match either the currently active session or the last active session when no session is active. π§
When using the env field to match on environment variables, you can specify only the environment variable name, or a name and value, for example env:MY_ENV_VAR=2. Tabs containing any window with the specified environment variables are matched. Similarly, var matches tabs containing any window with the specified user variable.
The field state matches on the state of the tab. Supported states are: active, focused, needs_attention, parent_active, parent_focused and focused_os_window. Active tabs are the tabs that are active in their parent OS window. There is only one focused tab and it is the tab to which keyboard events are delivered. If no tab is focused, the last focused tab is matched. The value focused_os_window matches all tabs in the currently focused OS window. π₯
and again, because the manpage insists: you can use the kitten @ ls command to get a list of tabs. π
--self [=no]β detach the tab this command is run in, rather than the active tab. it's about you personally. main character tab. π«Ά--help,-h [=no]β show help for this command. bestie behaviour honestly. πΈ
π GLOBAL OPTIONS π
these bad boys apply across the board, so don't skip them:
--toβ an address for the kitty instance to control. it corresponds to the address given to the kitty instance via the--listen-onoption or thelisten_onsetting inkitty.conf. If not specified, the environment variableKITTY_LISTEN_ONis checked. If that's 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. no kitty window, no messages. π--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 inkitty.conf. To use a blank password, specify--use-passwordasalways. π--password-file [=rc-pass]β a file from which to read the password. Trailing whitespace is ignored. Relative paths are resolved from the kitty configuration directory. Use-to read from STDIN. Usefd:numto read from the file descriptornum. Used if no--passwordis supplied. Defaults to checking for therc-passfile in the kitty configuration directory. π--password-env [=KITTY_RC_PASSWORD]β the name of an environment variable to read the password from. Used if no--password-fileis supplied. Defaults to checking the environment variableKITTY_RC_PASSWORD. π±--use-password [=if-available]β 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 toalwaysorneveruse the supplied password. If set toalwaysand no password is provided, the blank password is used. Choices:if-available,always,never. βοΈ
okay that's the whole page, you ate that honestly. πβ¨
π one little sign-off from the fine print: this is version 0.49.2, dated Oct 01, 2026, and it's the kitten-@-detach-tab(1) page. go detach some tabs, queen. ππ¦
π¦ where this page comes from
- arch rolling: kitty 0.49.2-1 Β· GPL-3.0-only
- nixpkgs unstable: kitty-bin 0.49.2
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms