Introduction¶
When debugging local projects in DSH, you typically have to type commands in the chat before hitting Enter, or open a separate terminal to run scripts. If your project already has run configurations defined (e.g., npm scripts, Gradle tasks, build scripts), going back and forth with copy-paste becomes tedious. Most run-related plugins require you to save a configuration first, name it, and pick a scope — dsh-quick-run takes the opposite approach: it reads what already exists in your project and exposes those scripts as a control in the session header. One click, and it runs.
What It Is¶
dsh-quick-run is a DSH client plugin that displays a Run widget in the tool area of the session header, similar to the run configuration panel in VS Code or IDEA. The widget reads project scripts from the current session’s working directory, supports one-click launching with real-time output, and requires no pre-saved configurations.
Maintainer: jiaowoCheung
Auto-Discovery and Configuration¶
The widget automatically scans the current project for executable scripts:
package.json→ eachscriptsentry, launched vianpm run <name>- Project root → each
*.ps1,*.bat,*.cmd,*.sh(.ps1files are run viapowershell -NoProfile -ExecutionPolicy Bypass -File; the rest viacmd.exe)
If the project has no scripts, the widget will say so honestly rather than fabricating entries.
Manual Pinned Configurations¶
When you need to add, rename, or override auto-discovered configurations, you can add a .dsh-quick-run.json file in the project root:
{
"configs": [
{ "name": "Run client", "command": "gradlew.bat runClient" },
{ "name": "Serve", "command": "npm run serve", "cwd": "." },
{ "name": "PowerShell", "script": "scripts/build.ps1" }
]
}
Field descriptions:
name: The label displayed in the dropdown menucommand: A command line, executed viacmd.exe /d /s /cscript: A script file relative to the project rootprogram+args: Directly launch an executablecwd: Working directory relative to the project rootenv: Additional environment variablesincludeDiscovered: Set tofalseto disable auto-discovery
Installation and Activation¶
Run the following in DSH:
dsh plugin --profile web add github:jiaowoCheung/dsh-quick-run
You can also install from a local directory via Plugins → Add Plugin.
After installation, the widget appears in the tool area of the session title bar (to the left of the … menu). The run directory is taken from the current session’s working directory, so each session runs the scripts of the project it is editing.
Widget Controls and Output¶
The widget provides three primary actions:
▶: Run the selected configuration. If that configuration is already running, it re-attaches to the existing process▾: Open the dropdown menu to select a configuration, view running configurations, edit configurations, refresh the list, or reset to auto-discovery■: Stop the run, terminating the entire process tree (usestaskkill /T /Fon Windows)
The output panel shows real-time output, status, exit code, and elapsed time, and auto-scrolls to the bottom until the user manually scrolls up.
Output is not written to the session log: the client polls the host-side webServer route via same-origin HTTP, so nothing is appended to the chat history and no commands are executed through the chat.
Limitations¶
- The server-side output buffer per run is 200 KB; the client display cap is 400 KB
- Completed runs are retained for 10 minutes, with a maximum of 20 runs tracked simultaneously
- Process handling is Windows-oriented (
cmd.exe,taskkill); on other platforms,commandis handed off to the default shell
Technical Notes¶
- No dependency on any
@deepseek-ai/*runtime packages: the client uses React from the host module table and renders the widget itself, so harness upgrades will not cause the widget to disappear - The host registers only one
webServerprefixed route (/dsh-quick-run/api), and every request is validated against the browser session
Use Cases¶
Ideal for developers who need to quickly launch local development scripts within a DSH session, especially in projects that already have npm scripts, Gradle tasks, or batch scripts. The plugin runs with the permissions of the current DSH process, so it is advisable to review the source code and license before installing.