npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

dsh-workspace-picker-path

v1.3.0

Published

Controls the directory the workspace picker opens at: a fixed custom path (typed, pasted, or chosen visually), or the last directory you successfully picked. Quoted paths and CJK are accepted; a This PC level reaches other drives.

Readme

dsh-workspace-picker-path

DSH(DeepSeek Harness)桌面端 / Web GUI 插件:控制点击“添加工作区”时目录选择框从哪里打开。

解决什么问题

DSH NEXT 桌面端点侧栏的“添加工作区”时,会打开操作系统原生的“选择文件夹”对话框,起始位置由主进程决定且没有传 defaultPath,因此每次都不是你想要的路径。插件在通用设置里加入一条“新建工作区弹窗起始路径”,并提供两个选项:

| 选项 | 行为 | | --- | --- | | 自定义路径 | 弹窗每次从你填写的目录打开;留空或该目录不可读时退回主目录,并在框内提示原因。 | | 记住上次选择 | 弹窗从你上次确认的目录打开(“确认”指点击“打开”,取消不记录);尚无记录时退回主目录。 |

两个选项以就地分段控件呈现,不是下拉菜单:设置面板是滚动容器,绝对定位的下拉会被裁剪,portal 出去又要压过宿主模态自身的层阶,两者插件都无法自证——原实现正是“点了没反应”(菜单打开在屏幕外)。两段并排可见,从根上消除这一类故障,也少一次点击。

路径带引号也能识别:从资源管理器“复制路径”得到的是 "D:\SORTS\…" 这种带双引号的串。插件在提交、跳转、以及每次打开弹窗读取设置时都会剥掉包裹引号(同时容忍单引号、中文引号、首尾空格),Host 侧写入与读取同样去引号,手工编辑设置文件也不会踩坑。中文路径全程支持。

自定义路径模式下另有「浏览…」按钮:复用同一个目录浏览器可视化选取起始路径(含「此电脑」跨盘、路径栏、新建文件夹),选定即写回并同步输入框;粘贴路径的方式完整保留,两条路并存。这个入口不会污染「记住上次选择」的值——只有工作区流程的确认才写记忆。

取舍

原生“选择文件夹”对话框的起始目录只能通过修改 resources/app.asar 的主进程代码(给 dialog.showOpenDialog 传 defaultPath)来控制,插件层拿不到,而且应用自动更新会覆盖这类补丁。

因此本插件用插件层的正规扩展点:以 priority −2 占用 ui-workspace 声明的两个目录流槽位(conversation.hero.workspace.directoryFlow、sidebar.workspaces.directoryFlow),压过桌面端内置的 −1 原生拾取器与 0 级应用内浏览对话框(single 槽位渲染优先级最低的那个),换成插件自带的应用内目录浏览器——代价是弹窗不再是资源管理器那个原生框,收益是起始路径完全可控、不改任何应用安装文件、卸载即还原。

界面能力对齐原生框:面包屑与↑上一层、可输入完整路径回车跳转、显示/隐藏隐藏项、新建文件夹、打开。

Windows 下额外提供**「此电脑」层**:D:\ 不是 C:\Users\… 的子目录,逐级向上永远走不到另一个盘,原生选择框靠“此电脑”节点解决,这里照做——面包屑恒为 此电脑 › …,从任意目录按 ↑ 走到盘根后继续上一步即进入盘符列表;Host 侧并发探测 A–Z,1.5s 超时丢弃卡住的空光驱(实测本机 2ms 返回 C:、D:)。POSIX 下所有路径都在 / 之下,面包屑已可达,故不提供该层。

安装

已随 profile 链接安装(link: 指向本目录,改文件即生效,Client 半边重载页面即可,Host 半边需重启 DSH 进程)。

# 用 plugin_manager 安装(推荐):action=install_bundle, target=本目录绝对路径

卸载

plugin_manager → remove_bundle dsh-workspace-picker-path。

删除数据:$DSH_HOME/workspace-picker-path.json(默认 C:\Users\<你>\.dsh\workspace-picker-path.json)。除此之外插件不写任何文件,不修改应用安装目录。

文件

| 文件 | 作用 | | --- | --- | | index.js | Host 半边:GET/POST /workspace-picker-path/api/settings 读写 {mode, customPath, lastPath},经 connection.requestRejection 信任栅栏,原子写 JSON。 | | client.js | Client 半边:通用设置行(settings.general.item,order 18)、−2 级目录流占用方与应用内浏览器、样式与中英文案。 | | cordis.patch.yml | 把 workspace-picker-path 插件行插入 profile。 | | locale/en.json、locale/zh.json | 插件管理器显示用的标题与描述。 | | icon.svg | 插件图标(原创)。 |

已知边界

  • 目录列表只列子目录(不列文件),与原生“选择文件夹”一致;超大目录会被 Host 截断并提示。
  • 起始路径按 Host(运行 dsh 的机器)的文件系统解析;远程浏览器场景下 Host 与浏览器不在同一台机器时,路径由 Host 侧解释。
  • 槽位是 single 且可被“更低 priority”的插件覆盖;若将来有别的插件用 < −2 注册同一槽位,本插件会被覆盖(这是官方推荐的 shadow 机制,不是错误)。