본문으로 건너뛰기
S

dsh-hide-workspaces

super-qaq/dsh-hide-workspaces

Hide a workspace from the sidebar without deleting it, and restore hidden workspaces or archived sessions from one manager.

설치

dsh plugin --profile web add github:super-qaq/dsh-hide-workspaces

README

Hide workspaces

English | 中文

Give the sidebar a Hide action for workspaces that keeps them registered.

DSH's Workspace registry has no archive flag for workspaces: a workspace leaves the sidebar only when its registration is deleted. This plugin adds the missing state instead of deleting anything.

Install

dsh plugin add dsh-hide-workspaces

Requires DSH 0.2.2-rc.1 – 0.2.x. Reload the Web UI after installing. To remove it, disable the bundle in Plugins.

What it does

  • Hide workspace — in the workspace row's … menu. The workspace row and its sessions leave the sidebar; the registration, the folder, the session logs, and the account order stay exactly as they were.
  • Archived and hidden — an icon in the workspaces header, beside Search, View options, and Add workspace. It appears while at least one Session is archived or one workspace is hidden, and opens one fixed-size manager with two lists:
    • Archived sessions — every archived Session, newest first, with its workspace, turn count, context occupancy (used / window), and date, and its own Unarchive action. This is the direct answer to the built-in all-or-nothing archived filter.
    • Hidden workspaces — each hidden workspace with its folder and the number of Sessions the hide still archives, and its own Restore action.
  • Search — the manager's field filters the open list by title, workspace, folder, or Session id. Switching lists or unarchiving rows never resizes the dialog.
  • Undo — the success notice after hiding restores it in one click.

In the collapsed rail the same entry sits above Settings instead.

Sessions

Hiding archives the workspace's sessions rather than leaving them behind: without that, filtering the workspace row would spill every session into the sidebar's Ungrouped bucket. Archiving keeps each session's account slot, so restoring unarchives exactly the sessions the hide archived and puts them back in their recorded positions. Sessions you had already archived stay archived.

A workspace whose sessions still carry running work is not hidden. The action is refused with a notice; stop the session (or wait for the turn to end) and hide then. Nothing is stopped on your behalf.

Persistence

The hidden list lives in the Host settings document under the plugin entry workspace-visibility (field hidden), so it survives reloads and restarts. In a browser where that settings form is unavailable, the plugin falls back to localStorage.

Archived Sessions

The Archived sessions list reads the same registry-global archive set the built-in filter uses, so it shows exactly what All conversations (show archived) would show, one row at a time, without mixing them into the groups. Unarchiving a row returns that Session to its recorded position. Sessions of a hidden workspace stay listed here too and carry a hidden workspace note: unarchiving one of them makes it visible again as an Ungrouped row until its workspace is restored.

Session figures

Turn counts come from the sessionStats projection and context occupancy from contextPressure; both are excluded from Session summaries, so the manager asks for each listed archived Session's projections once (a few rows at a time, capped at 80 per dialog). Figures appear as those reads land; a Session whose read fails simply keeps its title, workspace, and date. The counts are whole-log figures, unaffected by paging or compaction.

Limitations

  • The workspaces header has no plugin slot: its action strip is a fixed two-button cell that clips overflow. The header icon therefore reserves one more 28 px cell through the plugin's own stylesheet and anchors there. If a future DSH release changes that header's markup, the icon stops mounting and the sidebar-foot entry returns automatically; hiding and restoring keep working.
  • Workspace visibility is a sidebar projection. The filtered list also reaches the new-session workspace picker, so a hidden workspace is not offered as a target until it is restored.
  • A session created in a hidden workspace afterwards is not attached to the hidden record; restore the workspace and archive it again if you want it out of the default list.
  • The hidden list is stored per profile, and the plugin listens on the workspace projection of this DSH version. A future release that replaces that projection would need a matching update.
  • Hiding the workspace of the conversation you have open archives that conversation and returns the main view to New Session, exactly like archiving the row itself; restoring the workspace unarchives it.

Turning it off

Disable or remove the plugin in Plugins. Every hidden workspace reappears immediately; the sessions the plugin archived stay archived, so restore them from the archived filter if you want them in the default list again. The hidden field stays in cordis.patch.yml and is reused if you enable the plugin again.

관련 플러그인