Linux系统(Ubuntu/Arch)下Kitty安装指南
Kitty
Outlook
The fast, feature-rich, GPU based terminal emulator
This is a set of config files based on Kitty by Hydraallen.
Introduction
kitty is designed for power keyboard users. To that end all its controls work with the keyboard (although it fully supports mouse interactions as well). Its configuration is a simple, human editable, single file for easy reproducibility (I like to store configuration in source control).
The code in kitty is designed to be simple, modular and hackable. It is written in a mix of C (for performance sensitive parts), Python (for easy extensibility and flexibility of the UI) and Go (for the command line kittens). It does not depend on any large and complex UI toolkit, using only OpenGL for rendering everything.
Finally, kitty is designed from the ground up to support all modern terminal features, such as Unicode, true color, bold/italic fonts, text formatting, etc. It even extends existing text formatting escape codes, to add support for features not available elsewhere, such as colored and styled (curly) underlines. One of the design goals of kitty is to be easily extensible so that new features can be added in the future with relatively little effort.
Installation
Kitty is available in the official repositories of all major Linux distributions, and you can use your favorite package manager to install the kitty package. However, note that some Linux distribution packages are woefully outdated. kitty is available in a vast number of package repositories for macOS and Linux.
To install it, simply open a terminal and type the following command depending on your operating system:
- On Ubuntu and Debian-based distributions:
$ sudo apt update && sudo apt install kitty
- On Arch Linux based distributions:
$ sudo pacman -S kitty
- On Fedora Workstation
$ sudo dnf -y install kitty
After the installation process is complete, you can launch it from the Applications menu.
By the way, if you’re interested in the original way of installation, you can click here for more information.
Customization
Obviously, you can use the default settings and themes in your Kitty terminal, it’s very useful. However, I will show you some basic optional customizations that you can apply to your Kitty to make it even more beautiful.
If you don’t want to meet the trouble of configuring your own file, then you can clone my config file by using:
git clone git@github.com:Hydraallen/kitty.git ~/.config/kitty/
Or, if you enjoy these troubleshooting process, then keep to the following steps.
To create a configuration file ~/.config/kitty/
in the directory, you can do it in your manually create a new one in Explorer, or simply tape the following lines into your terminal.:
- For Vim users:
vim ~/.config/kitty/kitty.conf
- For Nano users:
nano ~/.config/kitty/kitty.conf
Copy and paste the following lines into the file:
# 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
# Window Size
remember_window_size yes
shell_integration no-title
To save the changes and quit, please press Escape
to exit the vim editor, then type :wq
.
Nano users can simply press Ctrl+O
and Ctrl+X
to save and exit.
Tape neofetch
if you’ve downloaded. And you may end up with an interface that looks similar to this:
Shortcuts
Tabs
Action | Shortcut |
---|---|
New tab | ctrl+shift+t (also ⌘+t on macOS) |
Close tab | ctrl+shift+q (also ⌘+w on macOS) |
Next tab | ctrl+shift+right (also ⌃+⇥ and ⇧+⌘+] on macOS) |
Previous tab | ctrl+shift+left (also ⇧+⌃+⇥ and ⇧+⌘+[ on macOS) |
Next layout | ctrl+shift+l |
Move tab forward | ctrl+shift+. |
Move tab backward | ctrl+shift+, |
Set tab title | ctrl+shift+alt+t (also ⇧+⌘+i on macOS) |
Windows
Action | Shortcut |
---|---|
New window | ctrl+shift+enter (also ⌘+↩ on macOS) |
New OS window | ctrl+shift+n (also ⌘+n on macOS) |
Close window | ctrl+shift+w (also ⇧+⌘+d on macOS) |
Resize window | ctrl+shift+r (also ⌘+r on macOS) |
Next window | ctrl+shift+\] |
Previous window | ctrl+shift+[ |
Move window forward | ctrl+shift+f |
Move window backward | ctrl+shift+b |
Move window to top | ctrl+shift+ |
Visually focus window | ctrl+shift+f7 |
Visually swap window | ctrl+shift+f8 |
Focus specific window | ctrl+shift+1 , ctrl+shift+2 … ctrl+shift+0 (also ⌘+1, ⌘+2 … ⌘+9 on macOS) (clockwise from the top-left) |
Other keyboard shortcuts
The full list of actions that can be mapped to key presses is available here.
Action | Shortcut |
---|---|
Show this help | ctrl+shift+f1 |
Copy to clipboard | ctrl+shift+c (also ⌘+c on macOS) |
Paste from clipboard | ctrl+shift+v (also ⌘+v on macOS) |
Paste from selection | ctrl+shift+s |
Pass selection to program | ctrl+shift+o |
Increase font size | ctrl+shift+equal (also ⌘++ on macOS) |
Decrease font size | ctrl+shift+minus (also ⌘+- on macOS) |
Restore font size | ctrl+shift+backspace (also ⌘+0 on macOS) |
Toggle fullscreen | ctrl+shift+f11 (also ⌃+⌘+f on macOS) |
Toggle maximized | ctrl+shift+f10 |
Input Unicode character | ctrl+shift+u (also ⌃+⌘+space on macOS) |
Open URL in web browser | ctrl+shift+e |
Reset the terminal | ctrl+shift+delete (also ⌥+⌘+r on macOS) |
Edit kitty.conf | ctrl+shift+f2 (also ⌘+, on macOS) |
Reload kitty.conf | ctrl+shift+f5 (also ⌃+⌘+, on macOS) |
Debug kitty.conf | ctrl+shift+f6 (also ⌥+⌘+, on macOS) |
Open a kitty shell | ctrl+shift+escape |
Increase background opacity | ctrl+shift+a>m |
Decrease background opacity | ctrl+shift+a>l |
Full background opacity | ctrl+shift+a>1 |
Reset background opacity | ctrl+shift+a>d |
Q&A
Please search the Frequently Asked Questions carefully before asking and contact TechJI members if needed.
Contrbuting
If you encounter any problems in using the project, you can submit an issue or fork this project to submit an pull request. For pull requests, please be sure to have consistent style to existing modules, follow PEP 8, have clear identifier naming, and have proper comments.