From terminal-guru
This skill should be used when diagnosing, fixing, or understanding Unix terminal display issues including terminfo database problems, Unicode/UTF-8 character rendering, locale configuration, TUI application display, SSH terminal setup, and terminal emulator configuration. Also use for tmux session management, session creation with sesh, pane logging, and environment setup with direnv. Use for garbled characters, wrong colors, broken box drawing, emoji rendering, character encoding problems, "create a tmux session", "set up pane logging", "configure sesh", or "session naming convention".
How this skill is triggered — by the user, by Claude, or both
Slash command
/terminal-guru:terminal-emulationThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Diagnose and fix Unix terminal display issues: terminfo capabilities, Unicode/UTF-8 rendering, locale configuration, and terminal emulator setup. Covers colors, box drawing, emoji, SSH terminals, and TUI applications.
Diagnose and fix Unix terminal display issues: terminfo capabilities, Unicode/UTF-8 rendering, locale configuration, and terminal emulator setup. Covers colors, box drawing, emoji, SSH terminals, and TUI applications.
Run comprehensive diagnostics to identify terminal, locale, and environment issues:
python3 scripts/terminal_diagnostics.py
The diagnostic script checks:
When to use: Start with diagnostics when users report any terminal display issues.
For detailed terminfo troubleshooting, refer to references/terminfo_guide.md which covers:
Common operations:
# Check current terminal's capabilities
infocmp
# Test color support
tput colors
# Verify terminfo entry exists
infocmp $TERM >/dev/null 2>&1 && echo "OK" || echo "Missing"
# Compare terminal types
infocmp -d xterm-256color tmux-256color
# Create custom entry
infocmp xterm-256color > custom.ti
# Edit custom.ti
tic -o ~/.terminfo custom.ti
For detailed Unicode guidance, refer to references/unicode_troubleshooting.md which covers:
Common fixes:
# Fix locale for UTF-8
export LANG=en_US.UTF-8
export LC_ALL=en_US.UTF-8
# Test Unicode rendering
echo "ASCII: Hello"
echo "CJK: 你好世界"
echo "Emoji: 😀 🎉 ✨"
echo "Box: ┌─┐│└┘"
# Fix box drawing (if showing as q, x, m, j)
export NCURSES_NO_UTF8_ACS=0
# Remove BOM from file
sed -i '1s/^\xEF\xBB\xBF//' file.txt
python3 scripts/terminal_diagnostics.py
Key information to verify:
| Symptoms | Domain | Reference |
|---|---|---|
| Wrong colors, broken function keys | Terminfo | references/terminfo_guide.md |
| Garbled text, emoji broken, box drawing issues | Unicode/UTF-8 | references/unicode_troubleshooting.md |
| Mouse click bindings not firing, wrong range value | Tmux mouse | references/tmux_mouse_bindings.md |
| Need to create/manage tmux sessions, set up logging | Tmux sessions | references/tmux_session_management.md |
Terminfo issues:
echo $TERM
export TERM=xterm-256color
tput colors # Should show 256
Unicode issues:
export LANG=en_US.UTF-8
export LC_ALL=en_US.UTF-8
locale | grep UTF-8
Add fixes to appropriate shell config file:
.zshenv - Environment variables (LANG, PATH).zshrc - Interactive config (TERM overrides)# In ~/.zshrc or ~/.bashrc
if [[ -n "$SSH_CONNECTION" ]]; then
export TERM=xterm-256color
export LANG=en_US.UTF-8
export LC_ALL=en_US.UTF-8
fi
# For tmux - add to ~/.tmux.conf
set -g default-terminal "tmux-256color"
set -ga terminal-overrides ",*256col*:Tc"
# For screen - add to ~/.screenrc
term screen-256color
Then in shell config:
if [[ -n "$TMUX" ]]; then
export TERM=tmux-256color
elif [[ -n "$STY" ]]; then
export TERM=screen-256color
fi
python3 scripts/terminal_diagnostics.pyecho $TERMexport TERM=xterm-256colortput colors (should show 256)locale | grep UTF-8export LANG=en_US.UTF-8export NCURSES_NO_UTF8_ACS=0references/unicode_troubleshooting.mdlocale | grep UTF-8echo "😀 🎉 ✨"references/unicode_troubleshooting.mdterminal_diagnostics.py - Comprehensive diagnostic tool for terminal, locale, and environment (supports --json mode)tests/display_tests.py - Display consistency tests (Python-based)tests/base.py - Shared test infrastructureterminfo_guide.md - Complete terminfo database reference and troubleshootingunicode_troubleshooting.md - Unicode/UTF-8 character rendering and encoding issuestmux_mouse_bindings.md - Named status bar ranges, correct mouse events, diagnostic technique, live binding vs bootstraptmux_session_management.md - Session creation with sesh, naming conventions, direnv environment setup, pane logging, session persistencenpx claudepluginhub totallygreg/claude-mp --plugin terminal-guruManages tmux sessions, windows, and panes for persistent remote workflows and shell scripting automation. Useful for long-running processes, SSH disconnects, and multi-pane terminal layouts.
Provides design patterns for terminal user interfaces: layout paradigms, keyboard navigation, visual systems, and TUI anti-pattern validation. Works with Ratatui, Ink, Textual, Bubbletea, or any TUI framework.