dsh-folder-drop: Drag a Folder into DeepSeek Harness to Get Its Native Absolute Path

Introduction

DSH’s composer natively only accepts files. The drag-and-drop chain only reads dataTransfer.files (the ComposerAttachments from @deepseek-ai/dsh-client-ui-attachment), and browsers never hand directory contents over as File. The result: dragging a folder either does nothing at all, or becomes a 0-byte empty shell in the attachment bar.

This plugin fills in this gap: drag a directory in → directly write the path into the draft, and hand it off to the agent’s own file tools to read.

What This Is

Drag a folder into the DSH Desktop composer to get its native absolute path. This is a client plugin maintained by chiyu-star499, released under the MIT license.

Core Features

  1. Pure file / pure image drag-drop: unchanged — fully handed back to DSH’s native attachment chain. The attachment bar, upload progress, failure retries, and image previews all remain as they are.
  2. Folder handling: this plugin takes exclusive ownership of the drop. It appends each item’s native absolute path, newline-separated, to the current draft; at the same time it synthesizes a dragend event so that DSH’s fullscreen drag overlay closes properly.
  3. Error handling: failed items are reported with their names via DSH’s own error notification — never silently ignored.

Installation and Activation

dsh plugin --profile desktop add github:chiyu-star499/dsh-folder-drop

Notes:
* Make sure the profile is desktop: DSH Desktop (GUI) runs under the desktop profile; dsh / dsh web defaults to web, and installing into web has no effect on the GUI.
* A restart is required: after installation you must restart DSH Desktop. Configuration and plugin-loading changes do not rely on patchReload: live.
* Installation method: add file:<directory> has been verified to perform a copy install (not a symlink). After modifying the source code you need to re-run add for the changes to take effect.

Typical Usage

Drag a folder into the DSH Desktop composer — its native absolute path appears directly in the draft. No copying, no uploading required.

Applicable Scenarios and Caveats

  • Feature boundary: only handles drop. Folders cannot be pasted, and the picker cannot select directories. In a normal browser there is no file-path bridge, so local paths cannot be obtained; in this case a clear error is raised rather than inserting incorrect content.
  • Mixed-drag behavior: when dragging a mix of items, files also go through “insert path” rather than “attachment upload”. DSH’s drop event cannot intercept only one item of the drag. If you want attachment upload, drag only files.
  • Avoid conflicts: this plugin overlaps in functionality with dsh-drag-and-drop and dsh-drop-to-path; do not install them together.

Summary

The plugin writes paths through DSH’s public input facade (ctx.conversation.input.for().setDraft(text)) and does not touch the input DOM. It relies on DSH Desktop’s ability to provide real paths, and is suitable for developers who need to reference local file paths directly within DSH.

羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye