Last updated: 2026-05-28

Shortcut Panel

Double-tap the terminal screen on your phone to open the shortcut panel. Tap shortcuts to send key combinations, tap commands to input slash commands — no need to memorize anything.

┌─ Shortcuts ─────────────────┐
│  [Claude] [Codex] [Gemini]  │  ← Auto-switches by tmux session name
│                              │
│  Ctrl+C       Interrupt      │
│  Ctrl+C,Ctrl+C  Force quit   │  ← Comma = send sequentially
│  Ctrl+L       Clear screen   │
│  Enter        Send           │
│  Ctrl+J       New line       │
│                              │
│  ── Commands ──              │
│  /clear       Clear chat     │
│  /compact     Compress       │
│  /model       Switch model   │
│  /quit        Exit           │
│                              │
│  [Dismiss]                   │
└──────────────────────────────┘

Quick Setup with AI Agent (Recommended)

No manual editing needed — let your AI tool auto-configure everything.

1. Copy this prompt

Click to expand the prompt
You are configuring the Hi Term shortcut panel. Hi Term is a mobile terminal app that connects to this PC via SSH. The shortcut panel appears when the user double-taps the terminal screen on their phone.

Your task: scan this tool's commands and shortcuts, then write a config file at ~/.hiterm/shortcuts.json.

## Step 1: Identify which tool you are

Check your identity against this table:

| Tool | Keywords | Project skills dir | User skills dir |
|------|----------|-------------------|-----------------|
| Claude Code | claude, anthropic | .claude/skills/ | ~/.claude/skills/ |
| Gemini CLI | gemini, google | .gemini/skills/ | ~/.gemini/skills/ |
| Codex CLI | codex, openai | .codex/skills/ | ~/.codex/skills/ |
| Opencode | opencode | .opencode/skills/ | (none) |

## Step 2: Scan for commands

Collect commands from these sources:

1. **Built-in slash commands**: /help, /clear, /init, /model, /quit, /config, /docs, etc.
2. **Project skills**: Read the skills directory listed above. Each subdirectory name or .md file is a skill/command.
3. **User skills**: Read the user-level skills directory if it exists.

Deduplicate. Keep only commands that are actually useful on a phone (skip config/setup commands that need a full keyboard).

## Step 3: Scan for shortcuts

Collect keyboard shortcuts that this tool supports:
- Cancel/interrupt: Ctrl+C
- Force quit: Ctrl+C,Ctrl+C
- Clear screen: Ctrl+L
- Navigate history: UP/DOWN
- Send: Enter
- Newline (no send): Ctrl+J
- Cut/paste: Ctrl+X, Ctrl+V
- Line nav: Ctrl+A, Ctrl+E, Ctrl+Left, Ctrl+Right
- Delete: Ctrl+W, Ctrl+U, Ctrl+K
- Tool-specific: Shift+Tab, Tab, Esc, Ctrl+Z, Ctrl+Y, etc.

## Step 4: Present for confirmation

Show the user a summary like:

  Detected: [Tool Name]

  Commands (tap to send):
    /help, /clear, /init, /model, ...

  Shortcuts (tap to send):
    Ctrl+C, Ctrl+L, Shift+Tab, ...

  Confirm? (y/n/edit)

Let the user remove items or reorder them.

## Step 5: Write the config

Read the existing ~/.hiterm/shortcuts.json. It has this format:

{
  "tools": [
    {
      "name": "ToolName",
      "keywords": ["keyword1", "keyword2"],
      "shortcuts": ["Ctrl+C", "Ctrl+L", ...],
      "commands": ["/help", "/clear", ...]
    }
  ]
}

Update or add your tool's entry in the "tools" array. Keep other tools' entries unchanged. Write the file back.

IMPORTANT: Write the actual file. Do not just show the JSON.

Or run hiterm shortcuts on your PC to print it directly in the terminal.

2. Paste into your AI agent

Open Claude Code, Gemini CLI, Codex, or Opencode, then paste the prompt. It will auto-detect the tool, scan commands and skills, and write the config.

3. Sync to your phone

On your phone, long-press the SSH host in the host list → tap Refresh shortcuts. Then double-tap the terminal to see the updated panel.


tmux Session Naming

The panel auto-switches tabs based on your tmux session name. The name must contain an AI tool keyword (case-insensitive):

AI Tool Keywords
Claude claude / anthropic
Codex codex / openai
Gemini gemini / google
Opencode opencode
# ✅ Auto-matches Claude tab
tmux new -A -s claude-frontend

# ✅ Auto-matches Gemini tab
tmux new -A -s backend-gemini

# ❌ No keyword — panel won't auto-switch
tmux new -A -s my-session

Manual Editing

The config file is at ~/.hiterm/shortcuts.json on your PC, auto-created by hiterm pair.

Comma Separator — Sequential Execution

Send the same shortcut multiple times consecutively:

"shortcuts": [
  "Ctrl+C",              // 1x
  "Ctrl+C,Ctrl+C",       // 2x (force quit)
  "Ctrl+C,Ctrl+C,Ctrl+C" // 3x
]

Works for any shortcut: "Ctrl+D,Ctrl+D", "Esc,Esc", etc.

Syncing Changes to Your Phone

After editing shortcuts.json on your PC, the phone won't pick up changes automatically. You need to manually refresh:

  1. In Hi Term, go to the host list (tap back until you see it)
  2. Long-press the SSH host
  3. Tap Refresh shortcuts

The updated shortcuts will appear the next time you double-tap the terminal.


Troubleshooting

Problem Solution
Panel shows blank cat ~/.hiterm/shortcuts.json on PC — if missing, run hiterm pair
Wrong tab selected Check tmux session name contains the right keyword
Changes not appearing Long-press host in host list → Refresh shortcuts. Check Tailscale connection.
Invalid JSON python -m json.tool ~/.hiterm/shortcuts.json to validate

Next Steps