Foreword¶
The plugin system of DeepSeek Harness (DSH) allows developers to extend client functionality. In the workspace sidebar, the default context menu only provides two options: “Rename” and “Delete Workspace.” When you need to view or edit the current workspace directory directly in the system file manager, the workflow can be cumbersome.
The dsh-folder plugin solves this problem by injecting a menu item that directly integrates the “Open Folder” action into the workspace context menu.
What Is This¶
dsh-folder is a DeepSeek Harness (DSH) plugin maintained by developer KDronin and released under the MIT License.
The plugin inserts a new entry into the “More Actions” menu of workspace items in the sidebar, allowing users to quickly invoke the system default application to open the directory where the current workspace is located. It reuses the native menu style and icons to ensure visual consistency.
Core Features¶
- Menu Injection: In the “three dots” menu of workspace items in the sidebar, it inserts an “Open Folder” option between “Rename” and “Delete Workspace.”
- System Invocation: After clicking the menu item, the plugin invokes the DSH Host capability
session.openWorkspacePath. The host passes the path to the system default application, thereby opening the directory in the file manager. - Bilingual Support: The UI supports Chinese and English.
- Error Feedback: If opening fails (for example, due to an invalid path resolution or an unsupported environment), the menu item displays visible prompt text (using the native danger color), and the error message is written to
console.errorto avoid silent non-response.
Installation and Activation¶
Install via Official Command¶
Install using the official DSH command-line tool:
dsh plugin --profile web add github:KDronin/dsh-folder
After installation, restart the dsh web process and refresh the page for the changes to take effect.
Manual Installation¶
Copy the dsh-folder directory under the node_modules directory of the DSH profile:
$target = Join-Path $env:USERPROFILE '.dsh\profiles\node_modules\dsh-folder'
Copy-Item -Recurse .\dsh-folder $target
Add the following content to the configuration file $HOME/.dsh/profiles/web/cordis.patch.yml:
- insert:
- id: dsh-folder
name: 'dsh-folder'
Restart dsh web and refresh the page.
Typical Usage¶
- Locate the target workspace in the DSH sidebar.
- Click the “three dots” menu on the right side of the workspace row.
- In the popped-up menu, click “Open Folder,” located between “Rename” and “Delete Workspace.”
- The system file manager will automatically open the directory where the workspace is located.
Technical Implementation and Notes¶
This plugin is a pure UI plugin, with its core logic in lib/client.js.
- Menu Injection Mechanism: To avoid racing with React commit timing, the plugin uses a
MutationObserverto listen for menu mount events. Once the menu appears, it injects the menu item and continuously guards the node while the menu exists. This solves the issue in older versions where a fixed delay caused some workspace menu items to be missing. - Capability Invocation: An older version attempted to call the non-existent
ctx.workspaces.openPath, causing an error. The current version has been corrected to call the correct Host capabilityctx.remote.session.openWorkspacePath. - Dependencies: The plugin depends on
@deepseek-ai/dsh-client-locale,@deepseek-ai/dsh-api-workspace-controller, and@deepseek-ai/dsh-client-ui-workspace, which differs from the original manifest’s@deepseek-ai/dsh-client-runtime. - Version Fallback: If you need to compare, debug, or test against an older version, you can specify the path of the old client bundle using the environment variable
DSH_FOLDER_CLIENT.
Conclusion¶
dsh-folder is a lightweight and purpose-specific tool that fills a gap in DSH workspace management by enabling direct access to the file system. For developers who frequently need to edit configurations or inspect logs through the file manager, it is a practical complement.