# kitty

From ArchWiki
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

kitty is a scriptable OpenGL based terminal emulator with TrueColor, ligatures support, protocol extensions for keyboard input and image rendering. It also offers tiling capabilities, like GNU Screen or tmux.

kitty is relatively new, of which first release (v0.1.0) was in Feb 2017. It however does not mean it is still premature.

## Installation

Install the kitty package.

## Usage

New tabs and windows can be created and resized through various `Ctrl+Shift` shortcuts. Layouts are switchable through `Ctrl+Shift+l` and can be saved/restored.

A full keyboard mode provides distinction between ambiguous keys like `Ctrl+i` vs `Tab`. Moreover, new text effects like curly-underline are also available for applications that support it.

### Kittens

kitty has a framework for creating subprograms called kittens. Some of them:

    $ kitty +kitten icat image.jpeg             # show image in the terminal (needs imagemagick)
    $ kitty +kitten diff file1 file2            # show diff of two files
    $ kitty +kitten clipboard                   # this kitten allows working with clipboard even over ssh

## Configuration

kitty stores its configuration in `~/.config/kitty/kitty.conf`. Fonts, colors, cursors and scrollback behaviors can be adjusted. You can see all available options in the official documentation. You can also find the default configuration file there.

## Tips and Tricks

### Enable IME support

Kitty support for IBus IME framework is disabled by default. To enable it, set the environment variable `GLFW_IM_MODULE=ibus`. This will also work with Fcitx5 due to the compatible IBus interface that it offers.

## Troubleshooting

### Terminal issues with SSH

When kitty is used to ssh into a remote that does not have its terminfo, various issues can occur. The solution is normally to copy over the terminfo. Kitty has an ssh kitten to automate exactly this.

    kitty +kitten ssh user@host

You may want to set it as an alias for `ssh`.

If for whatever reason you are unable to install the terminfo on the remote, you can try setting `TERM` to something that is more likely to be present. Note that this might disable some of the terminal's features.

    TERM='xterm-256color' ssh user@host

OpenSSH 8.7 implements the feature to pass a custom `TERM` environment variable to remote hosts. The version is not released yet (2021-07-22), but it is available in openssh-gitAUR. So now it is possible with a simple configuration snippet:

    ~/.ssh/config

    Host *
      SetEnv TERM=xterm-256color

## See also

- Official website
- GitHub repository

Categories:

- Terminal emulators
- Terminal multiplexers