The suckless terminal (st) with additional features that make it the best terminal emulator.
This build is based on st-flexipatch, which uses preprocessor directives to manage patches. This allows easy toggling of features without manual patching.
Unlike traditional st patching, this build uses C preprocessor directives to include/exclude patches at compile time. To enable or disable a patch, edit patches.h and set the value to 1 (enabled) or 0 (disabled):
#define ALPHA_PATCH 1 /* enabled */
#define FULLSCREEN_PATCH 0 /* disabled */
Then rebuild:
sudo make clean install
All patch options are documented in patches.h. The actual code for each patch lives in the source files, wrapped in #if PATCH_NAME ... #endif blocks.
| Keybinding | Action |
|---|---|
Ctrl+c or Ctrl+Shift+c |
Copy selection |
Ctrl+v or Ctrl+Shift+v |
Paste |
Right Click |
Paste from clipboard |
| Keybinding | Action |
|---|---|
Alt+k / Alt+Up |
Scroll up (1 line) |
Alt+j / Alt+Down |
Scroll down (1 line) |
Alt+u / Alt+PageUp |
Scroll up (page) |
Alt+d / Alt+PageDown |
Scroll down (page) |
| Keybinding | Action |
|---|---|
Alt+, |
Zoom in |
Alt+. |
Zoom out |
Alt+g |
Reset to default size |
Super+Shift+K/J |
Zoom in/out |
Super+Shift+U/D |
Zoom in/out (2x) |
| Keybinding | Action |
|---|---|
Alt+s |
Increase transparency |
Alt+a |
Decrease transparency |
Alt+m |
Reset transparency (opaque) |
| Keybinding | Action |
|---|---|
Alt+l |
Open URL handler |
Alt+y |
Copy URL to clipboard |
Alt+o |
Copy terminal output |
| Keybinding | Action |
|---|---|
Super+Shift+Enter |
Spawn new terminal in current directory |
Ctrl+Shift+U |
Unicode input (ISO 14755) |
Configured in patches.h:
| Patch | Description |
|---|---|
| alpha | Transparency support with configurable opacity |
| anygeometry | Dynamic geometry/borders |
| anysize | Resize to any pixel size |
| blinking_cursor | Cursor blinking support |
| boxdraw | Render box-drawing characters without font glyphs |
| clipboard | Clipboard integration (CLIPBOARD on selection) |
| columns | Doesn't cut text while resizing |
| copyurl | Select and copy URLs |
| externalpipe | Pipe terminal content to external commands |
| font2 | Secondary font support (emoji fallback) |
| iso14755 | Unicode input via dmenu |
| ligatures | HarfBuzz ligature support |
| newterm | Spawn new terminal in current directory |
| scrollback | Scroll history |
| scrollback_mouse | Scroll with mouse wheel + Shift |
| scrollback_mouse_altscreen | Mouse scroll in alternate screen |
| sixel | Sixel graphics support (for manga-tui, etc.) |
| swapmouse | Swap mouse buttons |
| sync | Synchronized updates to reduce flicker |
| xresources | Load settings from Xresources |
| xresources_reload | Live reload on SIGUSR1 |
~/.Xdefaults or ~/.Xresourcesxrdb merge ~/.Xresources && kill -USR1 $(pidof st)# Arch
pacman -S harfbuzz imlib2 libxft fontconfig freetype2
# Debian/Ubuntu
apt install build-essential libxft-dev libharfbuzz-dev libimlib2-dev
# Fedora
dnf install harfbuzz-devel imlib2-devel libXft-devel
# Void
xbps-install libXft-devel libX11-devel harfbuzz-devel imlib2-devel
git clone https://github.com/krisyotam/st
cd st
sudo make clean install
xrdb merge ~/.Xresources
Add the
xrdb mergecommand to your WM's autostart.
Requires a compositor (
xcompmgr,picom, etc.) for transparency.
Edit patches.h to toggle patches:
#define SIXEL_PATCH 1 /* Enable sixel graphics */
#define FULLSCREEN_PATCH 0 /* Disable fullscreen */
Edit config.def.h for:
After editing, rebuild:
rm config.h && sudo make clean install
This build reads settings from ~/.Xdefaults or ~/.Xresources. Changes reload live with:
xrdb merge ~/.Xresources && kill -USR1 $(pidof st)
Example Xresources:
st.font: JetBrainsMono Nerd Font:pixelsize=15
st.alpha: 0.85
st.color0: #282828
st.background: #282828
st.foreground: #ffffff
This build includes sixel support for displaying images in the terminal. Applications like manga-tui can render images directly in st.
To verify sixel support:
# If you have libsixel installed
img2sixel /path/to/image.png