zhangsan5213
dsh-right_sidebar
No description
- Stars
- 0
- Language
- JavaScript
- Created
- Aug 15, 2026
- Updated
- Aug 15, 2026
Introduction
dsh-right_sidebar
A dual-face dsh web plugin that replaces the built-in three-column layout with a five-column frame and adds a right-side Git workspace file tree with Content/Diff preview.
- Host half mounts a dedicated Connection RPC channel (
/workspace-files) usingctx.connection.rpc.handle - Browser half provides the five-column
rootframe (sidebar | center | file preview | files | details),ctx.layout, the theme presenter, and the file-tree/preview slots - File tree shows porcelain Git status badges, a changes-only filter, refresh, and per-file Content / Diff tabs
- Source Control view: staged/unstaged groups, stage / unstage / stage-all / unstage-all, and commit
- Bottom terminal dock: multiple PTY tabs, prompt output, input, and session close/kill
- No
/apimethod-table change
Requirements
- dsh
0.1.0-rc.5or later (tested on0.1.0-rc.5and0.1.0-rc.6) - A
webprofile
Install from a GitHub Release tarball
Download the .tgz from the latest release, then:
dsh plugin --profile web add ./zhangsan5213-dsh-right_sidebar-0.1.0.tgz
dsh web
dsh plugin detects the package's dsh.bundle declaration and activates its patch layer automatically; do not hand-edit the profile patch.
pnpm may print peer-dependency warnings during
dsh plugin add. This is expected: those peers are supplied by the installed dsh bundles and resolve at boot from the dsh installation, not from the profile'snode_modules.
Install directly from git
The repository commits the built lib/ artifacts, so no prepare script or allowBuilds permission is needed:
dsh plugin --profile web add github:zhangsan5213/dsh-right_sidebar#main
dsh web
Pin a commit (#<sha>) for reproducible installs.
Source Control
Open the right rail's Source Control icon (the branch glyph below Files). The panel groups the Git porcelain snapshot into Staged Changes and Changes. Stage individual files or all files, unstage them, and commit staged changes with the message box. Clicking a file opens it in the existing Diff preview.
Mutations are loopback-only (/scm channel) and are limited to git add, git reset, and git commit. Discard, push, and pull are intentionally not exposed.
Terminal
Open the terminal icon at the bottom of the collapsed right rail. The first open creates one PTY session in the current workspace; use the + button for additional tabs. Input is forwarded to the Host shell, output is polled through the loopback /terminal RPC channel, and each tab can be closed independently.
Current version: the dock is a real bottom grid row, so opening it squeezes the conversation/composer upward instead of covering them. Drag the top edge to resize the panel (double-click resets to 280px), and xterm fits the visible viewport so long output stays scrollable. The PTY column/row count is still fixed until the subprocess seam exposes a terminal resize verb.
What the bundle patch does
The package owns the full frame, so its cordis.patch.yml:
- disables the in-box
ui-layoutrow, and - inserts
@zhangsan5213/dsh-right_sidebaras one dual-face row.
ui-sidebar and ui-conversation keep working because this package provides the same ctx.layout service and registers the same root slot.
Development
pnpm install
pnpm run build
pnpm pack --pack-destination dist
Discoverability
- Add the
dsh-plugintopic to your plugin repository for discoverability.
Compatibility note
Because this bundle replaces the layout owner, upstream changes to ui-layout are not picked up automatically. If the five-column slots are merged upstream, this package can be simplified to a thin file-tree bundle that no longer disables ui-layout.