tui-testing
This skill should be used proactively whenever Claude needs to interact with, test, validate, verify, or observe a terminal user interface (TUI). This includes after writing TUI code and wanting to confirm it works, when debugging TUI behavior, when asked to verify UI changes, when running end-to-end validation of a TUI application, or any time Claude determines that launching and driving a TUI programmatically would help complete the task. Do not wait for the user to ask — use this skill autonomously whenever TUI interaction would validate work or answer questions.
What this skill does
# TUI Testing via tmux
Programmatically launch, interact with, and validate terminal user interface applications using tmux as a headless terminal driver.
## Why tmux
tmux provides a real PTY with proper dimensions, a rendered screen buffer readable via `capture-pane`, and keystroke injection via `send-keys`. The TUI app sees a real terminal and behaves identically to interactive use. No modifications to the application are required.
## Core Workflow
### Step 1: Ensure tmux is Available
```bash
which tmux || sudo apt-get install -y tmux
```
### Step 2: Launch the TUI in a Detached Session
Start a named, detached tmux session with explicit dimensions and run the TUI inside it:
```bash
tmux new-session -d -s <session-name> -x 120 -y 30 '<command to start TUI>'
```
- `-d` detaches immediately (headless)
- `-s` names the session for later reference
- `-x`/`-y` set terminal width/height so the TUI renders predictably
- The command runs inside the session's shell
Wait briefly for the TUI to initialize before sending keys:
```bash
sleep 2
```
### Step 3: Read the Screen
Capture the current visible contents of the terminal:
```bash
tmux capture-pane -t <session-name> -p
```
This returns plain text exactly as a human would see it, with ANSI escape sequences stripped. To include color/style info, add `-e`.
To capture specific line ranges (0-indexed):
```bash
tmux capture-pane -t <session-name> -p -S 0 -E 10
```
### Step 4: Send Keystrokes
Send keys to the TUI session:
```bash
# Navigation keys
tmux send-keys -t <session-name> Down
tmux send-keys -t <session-name> Up
tmux send-keys -t <session-name> Enter
tmux send-keys -t <session-name> Tab
tmux send-keys -t <session-name> Escape
# Letter keys (for TUI hotkeys like j/k/q)
tmux send-keys -t <session-name> j
tmux send-keys -t <session-name> q
# Ctrl combinations
tmux send-keys -t <session-name> C-c
tmux send-keys -t <session-name> C-q
# Type literal text (not interpreted as key names)
tmux send-keys -t <session-name> -l 'some text'
```
**Important**: After sending keys, wait for the TUI to re-render before capturing:
```bash
tmux send-keys -t <session-name> j && sleep 0.5 && tmux capture-pane -t <session-name> -p
```
### Step 5: Poll for Expected Content
When waiting for async operations (loading screens, background tasks):
```bash
for i in $(seq 1 30); do
output=$(tmux capture-pane -t <session-name> -p)
if echo "$output" | grep -q "expected text"; then
echo "Found it"
break
fi
sleep 0.5
done
```
### Step 6: Clean Up
```bash
tmux kill-session -t <session-name>
```
## Interaction Pattern
The general pattern for any TUI interaction is:
1. **Capture** the screen to understand current state
2. **Decide** which key to send based on what is displayed
3. **Send** the key
4. **Wait** briefly (0.3-1s) for re-render
5. **Capture** again to verify the result
6. **Repeat** until the goal is achieved
Always read the screen before and after actions. Do not blindly send sequences of keys without verifying intermediate state.
## Tips and Gotchas
- **Timing**: TUIs need time to render. Always sleep 0.3-1s between send and capture. For heavy operations (compilation, network), poll in a loop.
- **Key name collisions**: `tmux send-keys Enter` sends the Enter key. To type the literal word "Enter", use `tmux send-keys -l 'Enter'`.
- **Session naming**: Use unique session names to avoid collisions. Clean up sessions when done.
- **Terminal size matters**: Some TUIs render differently at different sizes. Match the expected terminal dimensions with `-x` and `-y`.
- **Nested tmux**: If the TUI itself uses tmux internally (e.g., opens a tmux session inside a container), the inner tmux session is independent. Target the outer session for TUI-level interaction, or use `docker exec` to interact with the inner session.
- **Alt screen**: Most TUIs (bubbletea, etc.) use the alternate screen buffer. `capture-pane` handles this correctly.
- **Resize**: Test different sizes with `tmux resize-window -t <session-name> -x <w> -y <h>`.
Related in Design
contribute
IncludedLocal-only OSS contribution command center. Auto-refreshes the user's in-flight PR and issue state on invoke so conversations start with full context — no need to brief Claude on what's in flight. Helps the user find issues to contribute to on GitHub, builds per-repo dossiers of what each upstream expects (CLA, DCO, branch convention, AI policy, draft-first, review bots, issue templates), runs deterministic gates before any external action so AI-assisted contributions don't reach maintainers as slop. State is markdown-only: candidate files at ~/.contribute-system/candidates/, repo dossiers at ~/.contribute-system/research/, append-only event log at ~/.contribute-system/log.jsonl. No database, no cloud calls. Use when the user asks about their PRs / issues / contributions, wants to find new work to take on, claim an issue, build/refresh a repo's dossier, or draft a Design Issue or PR. Trigger with "/contribute", "what's my PR status", "find a contribution", "claim issue X", "draft a Design Issue for Y", "refresh dossier for Z".
architectural-analysis
IncludedUser-triggered deep architectural analysis of a codebase or scoped subtree across eight modes — information architecture, data flow, integration points, UI surfaces, interaction patterns, data model, control flow, and failure modes. This skill should be used when the user asks to "diagram this codebase," "map the architecture," "show the data flow," "give me an ERD," "trace control flow," "find the integration points," "verify the layout pattern," "audit the UX architecture," or any similar request whose primary deliverable is mermaid diagrams plus cited reports under docs/architecture/. Dispatches haiku/sonnet sub-agents in parallel for per-mode exploration, then verifies every citation mechanically before any node lands in a diagram. Not for one-off prose explanations of code (use code-explanation) or for high-level system design from scratch (use system-design).
mcp
IncludedModel Context Protocol (MCP) server development and tool management. Languages: Python, TypeScript. Capabilities: build MCP servers, integrate external APIs, discover/execute MCP tools, manage multi-server configs, design agent-centric tools. Actions: create, build, integrate, discover, execute, configure MCP servers/tools. Keywords: MCP, Model Context Protocol, MCP server, MCP tool, stdio transport, SSE transport, tool discovery, resource provider, prompt template, external API integration, Gemini CLI MCP, Claude MCP, agent tools, tool execution, server config. Use when: building MCP servers, integrating external APIs as MCP tools, discovering available MCP tools, executing MCP capabilities, configuring multi-server setups, designing tools for AI agents.
react-native-skia
IncludedDesign, build, debug, and optimise high-polish animated graphics in React Native or Expo using @shopify/react-native-skia, Reanimated, and Gesture Handler. Use when the user wants canvas-driven UI, shaders, paths, rich text, image filters, sprite fields, Skottie, video frames, snapshots, web CanvasKit setup, or performance tuning for custom motion-heavy elements such as loaders, hero art, cards, charts, progress indicators, particle systems, or gesture-driven surfaces. Also use when the user asks for fluid, glow, glass, blob, parallax, 60fps/120fps, or GPU-friendly animated effects in React Native, even if they do not explicitly say "Skia". Do not use for ordinary form/layout work with standard views.
plaid
IncludedProduct Led AI Development — guides founders from idea to launched product. Six capabilities: Idea (discover a product idea), Validate (pressure-test the idea against fatal flaws, problem reality, competition, and 2-week MVP feasibility), Plan (vision intake + document generation), Design (translate image references into a design.md spec), Launch (go-to-market strategy), and Build (roadmap execution). Use when someone says "PLAID", "plaid idea", "help me find an idea", "product idea", "idea from my business", "idea from my expertise", "plaid validate", "validate my idea", "pressure-test", "is this idea good", "find fatal flaws", "validate the problem", "plan a product", "define my vision", "generate a PRD", "product strategy", "plaid design", "design from image", "translate image to design", "create design.md", "extract design tokens", "plaid launch", "go-to-market", "launch plan", "GTM strategy", "launch playbook", "plaid build", "build the app", "start building", or "execute the roadmap".
nextjs-framer-motion-animations
IncludedAdds production-safe Motion for React or Framer Motion animations to Next.js apps, including reveal, hover and tap micro-interactions, whileInView, stagger, AnimatePresence, layout and layoutId transitions, reorder, scroll-linked UI, and lightweight route-content transitions. Use when the user asks to add, refactor, or debug Motion or Framer Motion in App Router or Pages Router codebases, especially around server/client boundaries, reduced motion, LazyMotion, bundle size, hydration, or route transitions. Avoid for GSAP-style timelines, WebGL or 3D scenes, heavy scroll storytelling, or CSS-only effects unless Motion is explicitly requested.