Kitty is a cross-platform GPU-based terminal emulator. It is feature-rich, written in Python and Objective C. It can easily be controlled from shell prompt, over ssh and through scripts. It is a light-weight emulator, build for low resource usage but to give higher experience on images and videos. It supports images, Unicode, mouse protocol, true-color, hyperlinks among others.
In this guide, we are going to be looking at how to install and customize Kitty terminal emulator on Linux.
Install Kitty terminal emulator on Linux | macOS using Package managers
Installation can be done using package managers as shown below.
# Ubuntu / Debian sudo apt-get update sudo apt-get install kitty # Arch Linux / Manjaro $ sudo pacman -S kitty # Fedora $ sudo dnf -y install kitty # macOS $ brew install kitty
To open, just type ‘kitty’ on your terminal.
You should also notice ‘kitty’ has been added to your desktop applications and you can launch it from there.
Install Kitty terminal emulator on Linux | macOS using installer script
On MacOS and Linux, you can install kitty from pre-built binaries. Simply run the below command:
curl -L https://sw.kovidgoyal.net/kitty/installer.sh | sh /dev/stdin
The above command installs the binary in ~/.local/kitty.app/bin/ on Linux and /Applications/kitty.app/bin directory on MacOS. Now launch it by the below command
Consider adding the binary location in your PATH.
$ vim ~/.bashrc export PATH=$PATH:~/.local/kitty.app/bin # For Zsh $ vim ~/.zshrc export PATH=$PATH:~/.local/kitty.app/bin
It should open a terminal as below:
Install Kitty Terminal Emulator on Linux | macOS from source
You can also install kitty from source. You need to ensure that you have the following dependencies installed:
- python 3.5 and later versions
- harfbuzz 1.5.0 and later versions
- freetype (macOS)
- fontconfig (macOS)
- libcanberra (macOS)
- ImageMagick (optional, for kitty icat tool to display images in the terminal)
- pygments (optional, for syntax highlighting in kitty +kitten diff)
Once you have the dependencies installed, clone kitty repository from Github as below:
git clone https://github.com/kovidgoyal/kitty
Change to the directory of the downloaded content and install kitty
cd kitty make
You can then launch as below:
Once installed, you are now ready to start using kitty terminal emulator. Having launched, you can run different programs on different windows using
Important Kitty Terminal Emulator Shortcuts
The following are some of the useful shortcuts to be used with Kitty:
|Scroll page up||ctrl+shift+page_up|
|Scroll page down||ctrl+shift+page_down|
|New OS window||ctrl+shift+n|
Working with ‘tab’
|Move tab forward|
|Move tab backward|
|Set tab title|
And for windows;
|Move window forward|
|Move window backward|
|Move window to top|
|Focus specific window|
How To Customize Kitty Terminal Emulator
Kitty terminal emulator can be customized using a configuration file. Kitty is highly customizable. Here, you can change fonts size and family, background and foreground colors and even define shortcuts to ease your use among others. Launch kitty and create a configuration file as below.
sudo vim /.config/kitty/kitty.conf
Add the following content to change font, background and foreground colors.
# font_family Input Mono font_family Fantasque Sans Mono italic_font auto bold_font auto bold_italic_font auto # Font size (in pts) font_size 18.0 # The amount the font size is changed by (in pts) when increasing/decreasing # the font size in a running terminal. font_size_delta 2 # The foreground color foreground #c0b18b # The background color background #202020
Save the file, exit the terminal and launch back in. You should notice the difference as below:
Kitty Completion Configurations for Bash, Zsh and Fish
For popular shells; bash, zsh and fish, kitty comes with the completion for the kitty command.
# bash - Add the following to your ~/.bashrc source <(kitty + complete setup bash) #Older versions of bash (for example, v3.2) do not support process substitution with the source #command, in which #case you can try an alternative: source /dev/stdin <<<"$(kitty + complete setup bash)" # zsh - Add the following to your ~/.zshrc autoload -Uz compinit compinit # Completion for kitty kitty + complete setup zsh | source /dev/stdin #The important thing above is to make sure the call to kitty to load the zsh completions happens after the call to compinit. #fish #For versions of fish earlier than 3.0.0, add the following to your ~/.config/fish/config.fish. Later versions source completions by default. kitty + complete setup fish | source
You have successfully installed and configured Kitty Terminal Emulator on Linux. Kitty is lightweight and highly customizable GPU based terminal emulator. Enjoy using Kitty. More interesting guides below: