Preface¶
When running agent sessions in DeepSeek Harness (DSH), the working directory is often the workspace of the current session. If you are also using CodeBuddy CN for IDE-side development, the common practice is to manually switch to the local directory and then open the same folder in CodeBuddy—requiring aligned paths and repetitive steps.
The community plugin dsh-open-in-codebuddy (maintainer lovezi0, GitHub: lovezi0/dsh-open-in-codebuddy) integrates this step into the native “Open In…” button group at the session header. After selecting CodeBuddy CN, it uses the local CLI entry to open the current session directory. The buttons and menu are not drawn by this plugin itself, but are uniformly rendered by the base dsh-open-in-app-base; this plugin is only responsible for registering the target, detecting availability, and defining “how to open”. The following introduces the positioning, installation, and limitations you need to know when using it.
What is this¶
dsh-open-in-codebuddy is a third-party DSH plugin categorized as a workflow. It registers a CodeBuddy CN target to the “Open In…” toolbar at the session header, allowing you to open the current session’s workspace directory in local CodeBuddy CN with one click.
Unlike forking or modifying the DSH host, or relying on the native open-in-app application directory approach: this plugin brings its own local routing, directly passing directory parameters to the CLI entry of CodeBuddy CN; it does not fork or modify the host.
The current npm package version is 0.1.4 (MIT License). engines.dsh requires >=0.2.1-alpha.1; the README badge marks the adaptation relationship with DeepSeek Harness 0.2.1-rc.2. Plugin directory page: skillhub.cn/plugins/lovezi0/dsh-open-in-codebuddy (a community independent site, with no official affiliation with DeepSeek / High-Flyer).
Core Features¶
The following capabilities are derived from the repository README and package.json descriptions.
Cross-end Consistency: The web profile and Desktop (Electron) profile use the same channel and the same code.
Native Integration: The target is merged into the “Open In…” button group at the session header; button size, icon specifications, and the menu are rendered by the base dsh-open-in-app-base. This plugin does not draw controls itself.
Auto-detect Installation Location: The order is “Explicit Configuration → Registry App Paths → Common installation layouts on each drive letter”. If detection fails, the target will not appear in the menu (equivalent to unavailable in remote / SSH scenarios).
Security Fence: The routing only accepts same-origin requests from loopback / trusted hosts and rejects cross-site requests; the target directory must be a local absolute path and must actually exist.
Platform Limitation: Effective only on Windows; on non-Windows platforms, the target is permanently unavailable.
Installation and Enablement¶
This plugin depends on the base dsh-open-in-app-base (the “Open In…” button group at the session header). You must install the base first, then install this plugin. If the base is missing, this plugin will not report an error, but there will be no button group to mount the target.
Both packages are published on npm. Install by package name (the latest version is installed by default; you can use package-name@version to pin a specific version if needed).
# web profile installation (base first, then this plugin)
dsh plugin --profile web add dsh-open-in-app-base
dsh plugin --profile web add dsh-open-in-codebuddy
# desktop profile installation (base first, then this plugin)
dsh plugin --profile desktop add dsh-open-in-app-base
dsh plugin --profile desktop add dsh-open-in-codebuddy
Alternative: Install directly from a remote repository tag (the tag source includes build artifacts lib/, requiring zero build on the installation side). The syntax is 'github:lovezi0/dsh-open-in-codebuddy#vX.Y.Z' (replace vX.Y.Z with the actual tag, which must be consistent with the version in package.json).
It is recommended to review the source code and MIT license yourself before installation; the plugin executes opening logic on the local machine with the current dsh process permissions. For permission and path validation strategies, refer to the repository description.
Configuration¶
You can override settings in the profile’s cordis.patch.yml by the plugin id, without modifying the plugin code:
- id: open-in-codebuddy
config:
codebuddyHome: "" # CodeBuddy CN installation root directory; empty = auto-detect
Typical Usage¶
- Install the base and this plugin in either the web or desktop profile as described in the previous section.
- Open a session in DSH and ensure the workspace directory is a local absolute path (in remote scenarios or when there is no local CodeBuddy, the target usually does not appear in the menu).
- Find the “Open In…” button group at the session header and select CodeBuddy CN.
- The base will probe the availability via the plugin host route (
GET open-in-codebuddy/available); upon clicking, it POSTs the current session directory (POST open-in-codebuddy/open). After validation passes, it launches the local instance in a way equivalent to the official CodeBuddy CN command-line shim (if an instance already exists, it will open a new window).
How it Works (Brief)¶
The plugin registers the CodeBuddy CN target at the session header, which is rendered as a menu item in the button group by the base. The host side validates the request source and path before launching CodeBuddy CN; implementation details can be found in the source code comments of the repository.
Scenarios and Notes¶
Target Audience: Developers using DSH on Windows (web or Desktop profile) who have CodeBuddy CN installed locally and wish to open the same workspace with one click within the session.
Things to Note:
- Do not expect this entry to be available on non-Windows platforms.
- If the CodeBuddy installation path is not detected, or directory validation fails, the target will not appear in the menu or cannot be opened.
- Since version 0.1.3, the practice of “bundling the base by default” has been removed: the base must be installed separately, otherwise there is only a mount point but no button group.
- Node runtime requirement is >=20 (see
engines.nodeinpackage.json).
Conclusion¶
dsh-open-in-codebuddy consolidates “Open current DSH workspace in CodeBuddy CN” into a single target within the session header’s “Open In…”, and divides labor with dsh-open-in-app-base: the base handles the UI, while this plugin handles CodeBuddy CN’s availability and opening method.
- Directory Page: https://www.skillhub.cn/plugins/lovezi0/dsh-open-in-codebuddy
- Source Code & README: https://github.com/lovezi0/dsh-open-in-codebuddy