Foreword¶
When developing agents or AI CLI workflows in the DSH Web GUI, a common requirement arises: the conversation interface is already open on the page, but you still need an accessible shell to execute commands, view logs, switch directories, or continue working with full-screen terminal programs like Codex or Claude Code.
dsh-plugin-terminal is a bottom terminal panel plugin designed for the DeepSeek Harness (DSH) Web GUI. It provides a multi-tab shell panel at the bottom of the page, using node-pty under the hood—working through ConPTY on Windows and openpty on Linux/macOS.
What This Is¶
dsh-plugin-terminal is a DSH Web GUI plugin that adds an interactive terminal panel at the bottom of the viewport, aligned with the session column. The repository points to siberiah2o, and it is licensed under MIT.
The core problem it solves is enabling DSH Web GUI users to open, switch, and restart multiple terminal tabs at the bottom without leaving the browser page, while maintaining terminal sessions, working directories, and scrollback history.
Core Capabilities¶
- The bottom terminal panel is fixed to the bottom of the DSH Web GUI viewport and aligned with the session column.
- Supports multi-tab shell functionality: create, close, and restart tabs; processes continue running when switching tabs; active sessions can be restored after page refresh or workspace switch.
- Terminals remember their working directory: new tabs start from the current DSH workspace; after a
dsh webrestart, restart operations return to the terminal’s original directory, not the service startup directory. - Session metadata and scrollback are persisted to
$DSH_HOME/plugin-data/terminal/. After adsh webrestart, these terminals can be restored as exited historical tabs. - Supports xterm.js 6 features, including color, blinking cursor, alternate screen, Unicode v11 CJK width table, and 10,000 lines of scrollback.
- Connects to PTY via a WebSocket bidirectional channel, providing a dark terminal surface in both light and dark themes.
- Supports mouse selection copy, right-click paste, and
Ctrl+Vpaste; when the clipboard API is available, it supportsCtrl+Shift+C/Ctrl+Shift+Vfor copy and paste. - Configurable panel toggle shortcut, with support for dragging to adjust panel height—the panel size is remembered.
- Adapted for full-screen AI coding CLIs like Codex and Claude Code, with support for truecolor and CJK rendering.
Installation and Enabling¶
The official installation command is:
dsh plugin --profile web add dsh-plugin-terminal && dsh web
Note: This is a DSH plugin that must be installed and enabled via dsh plugin. Do not use the ordinary:
npm i dsh-plugin-terminal
Typical Usage¶
Configuring Shortcuts and Shell Commands¶
Plugin behavior can be configured in the DSH settings document at $DSH_HOME/settings.yaml under the terminal section; it can also be modified via the GUI under Settings → Plugins.
Example configuration:
terminal:
toggleShortcut: ctrl+j
shellCommand: cmd.exe /k "C:\cmder\vendor\init.bat"
Where:
toggleShortcutis used to toggle the bottom terminal panel.shellCommandspecifies the command line to execute when a new terminal session starts.
shellCommand is used as-is without injecting additional flags. The command line is split by spaces, preserving double quotes, so quoted paths work correctly.
Overriding Configuration with Environment Variables¶
The following environment variables can override the configuration in the settings document and also apply to headless compositions:
DSH_PLUGIN_TERMINAL_TOGGLE_SHORTCUT
DSH_PLUGIN_TERMINAL_SHELL_COMMAND
Working with Full-Screen CLIs like Codex and Claude Code¶
dsh-plugin-terminal includes rendering adaptations for full-screen TUIs like Codex and Claude Code, including truecolor and CJK width handling.
If Claude Code rendering exhibits flickering, you can use the following in the session:
/tui fullscreen
Or use:
CLAUDE_CODE_NO_FLICKER=1 claude
To switch to the non-flickering fullscreen renderer.
When using within tmux, it is recommended to set:
TERM=tmux-256color
And ensure the tmux version is 3.4 or newer; you can add terminal-overrides if necessary.
Applicable Scenarios and Considerations¶
Suitable for the following use cases:
- Using both the conversation interface and shell simultaneously in the DSH Web GUI.
- Running full-screen AI coding CLIs like Codex or Claude Code within the browser page.
- Needing to preserve terminal working directories, session history, and scrollback in the Web GUI.
- Requiring multiple terminal tabs for parallel work and avoiding frequent switching to local terminal windows.
Before use, please note:
- The plugin runs with the current
dshprocess permissions. Review the source code and license before installation. - When the GUI is opened via remote HTTP (not HTTPS and not localhost), the browser disables
navigator.clipboard. In this case, the plugin falls back toexecCommandfor copying and allows the browser’s native right-click menu for pasting. - If the toggle shortcut is also consumed by the terminal (e.g., a shortcut has meaning in the shell), when the terminal panel has focus, the keypress will be sent to the shell first, rather than toggling the panel.
shellCommanddoes not automatically append flags; it must be written as the actual command line.
Links¶
- Directory page link from the provided plugin clue:
https://www.skillhub.cn/plugins/siberiah2o/dsh-plugin-terminal - GitHub repository:
https://github.com/siberiah2o/dsh-plugin-terminal