DSH sessions can be archived, but archiving is not deleting: the session files stay in the $DSH_HOME sessions directory. To actually remove one, users dig through the filesystem by hand — a risky operation against an internal storage layout.
The demand
As of 2026-09-17 the same request appears in at least six independent official Discussion threads: #5744 (8 upvotes, describing the risks of manual deletion in detail), #3075 (6), #2772 (5), #3339 (4), plus #6845 and #5057. Privacy-sensitive conversations — sessions where the agent handled credentials, say — are the most honest motive behind it.
The gap
The indexed layer has exactly two adjacent implementations: lsz-asd/dsh-plugin-session-delete (32★) and xohmai/dsh-session-delete (10★). Both do the delete action only, with no management surface. For a feature requested six times, that is effectively no supply.
Proposed shape
Half host service, half client UI. The host side wraps safe session operations (archive-then-delete, confirm before delete, leave an audit trail); the client side adds a context-menu item to the session list and a “Session manager” settings card (multi-select, sort by time/size, total footprint).
Implementation notes
- Session storage and subsystem behavior: the official docs docs/subsystems/session.md, persistence.md and spill.md. A session is more than one file — a partial delete is worse than none.
- The official pattern for the settings card: docs/cookbook/adding-a-settings-card.md.
- Deletion is irreversible: confirm by default, and consider a soft delete (move to a trash directory, purge after 7 days).
The MVP
A “Delete permanently” item in the session list with a confirmation dialog and a result toast. Everything else is incremental.
Risks
This plugin touches DSH’s internal storage layout, and the project is in developer preview with breaking changes — a layout change could make the plugin delete the wrong thing. Declare a dshTarget range and re-verify on every harness release. That is also why it rewards a maintainer who keeps up: the first mover accumulates the most real compatibility knowledge.
FAQ
Won’t the official team do this?
Maybe. But six threads across August and September 2026 have no official response, so the window is real — and even if they ship a delete, a session manager (batch, statistics, soft delete) remains a superset.
What if something is deleted by mistake?
With soft delete as the default, it is recoverable. A hard delete must say “irreversible” in the UI in so many words.