Introduction¶
Sidebar management in DeepSeek Harness (DSH) typically requires combining two plugins to achieve basic functionality: one handles the “Pinned/Recent” columns, and the other handles the context menu. This hybrid approach has two issues: first, the columns plugin hides the official session rows and renders its own; second, the menu plugin locates IDs based on official rows, causing the menu to silently fail on pinned rows. dsh-sidebar-pins combines these two features into one. It renders the pinned bar itself while parsing official rows to write the data-dsh-pins-id attribute. Both share the same menu implementation, ensuring full functionality is available on all rows.
Installation¶
Install the plugin using the DSH CLI.
dsh plugin --profile desktop add github:boyl/dsh-sidebar-pins
For the Web profile, replace desktop with web. You must restart DSH Desktop after installation (the bundle layer only composes at startup). To uninstall, run:
dsh plugin --profile desktop remove dsh-sidebar-pins
Features¶
The sidebar is divided into “Pinned” and “Recent” columns, each scrolling independently. Pinned sessions do not appear in the Recent list, and newly pinned items are placed at the top.
Session Management¶
On any session row, a pin icon 📌 appears on hover. Clicking it pins or unpins the session. The icon in the pinned bar is solid brand blue.
Right-clicking, double-clicking, or clicking the ⋯ button at the end of a row pops up a menu containing the following options:
- Pin / Unpin: Moves the current session to the pinned bar.
- Rename: Calls
ctx.sessions.binding(id).session.rename(). - Mark as Unread / Read: Marks status; an orange bar appears on the left side of the row.
- Archive: Calls
ctx.workspaces.archiveSession(). - Fork: Calls
ctx.sessions.fork()and opens the child session. - Copy: Supports copying the session link, title, or ID to the clipboard.
- Open in new window: Opens via the
?session=<id>deep link. - Reveal in file manager: Calls the official
POST /open-in-app/openroute.
Workspace Management¶
Workspace rows also support right-click, double-click, or ⋯ menus. Features include:
- Pin Workspace: Calls
ctx.workspaces.insertBefore()to move the workspace to the top. - Rename: Calls
ctx.workspaces.rename(). - New Session: Calls
ctx.workspaces.startSession(). - Copy Path: Copies the path to the clipboard.
- Reveal in file manager: Calls the official route.
- Delete workspace (with disk): This is a special feature. Since the renderer does not have filesystem permissions, this operation is implemented via the Host route
POST /dsh-sidebar-pins/delete-workspace. This route includes strict validation: it only acceptsworkspaceIdand a confirmation name, rejects dangerous paths (such as/,$HOME, etc.), and requires secondary confirmation.
Native Button Takeover¶
The plugin takes over the official row-end ⋯ button. It intercepts clicks during the capture phase to pop up the full menu. The + new session button on workspace rows retains its native behavior and is unaffected.
Data Storage¶
All state is stored in the browser’s localStorage under the key dsh-sidebar-pins.v1, with the structure { v, pinned[], unread[], pinnedWorkspaces[] }.
On first launch, the plugin imports data from legacy plugins (such as dsh-codex-pins.v1, dsh-workspace-menu:v1) and deletes the old keys upon successful import.
Notes¶
- Session Deletion Limitations: The plugin does not implement the “Delete Session (including disk records)” feature, as this depends on third-party plugins or modifying core code.
- Dependencies: The sidebar layout relies on native DOM elements like
role="tree", classes (e.g.,sessionRow,groupSection), and the React Fiber structure. If a DSH update causes changes to these underlying structures, the plugin may fail. - Permissions: The plugin runs with the permissions of the current DSH process. You should review the source code and license before installation.
Summary¶
dsh-sidebar-pins solves the fragmentation of DSH sidebar management through unified rendering and menu logic. It provides a Codex-style pinning experience and a comprehensive context menu covering all rows. For developers who need to frequently manage the order of sessions and workspaces, this is a direct efficiency booster.
Project URL: https://github.com/boyl/dsh-sidebar-pins