Skip to content

v0.3.3

Choose a tag to compare

@33moren33 33moren33 released this 23 Aug 15:37
· 4 commits to main since this release

npm 上的插件,装得上,也起得来了。

第三方插件多数不随包带官方依赖——它们指望在运行的那台 dsh 身上现拿零件,所以从 dsh-box 装这类包,dsh 会因为找不到零件拒载整棵插件树。

这一版从根上解决:下载一次,每个 dsh 版本各配一套对版的零件货架(硬链接,不占多余磁盘),沙箱换哪个版本启动都自动对版;装进日常档案柜则是整份拷进去——之后你自己敲 dsh 一样加载,把 dsh-box 删掉也毫发无损。窗口可以按包名从 npm 装,下载进度实时可见。

随后真跑了一次完整回环,又修掉六件事

装一个记忆插件,再装一个聚合包(一个包带 21 个插件)、重启沙箱、确认 dsh 真的加载——这六件只有真装一次才会撞见,此前 407 项自动验收一条都没抓到。

  • 同时装两个插件会把包树写坏。实测两条并发安装互相打崩在一个双方共同的依赖上。现在一次只许一个,第二条会告诉你正在装哪个、去哪儿看它。
  • 镜像少一个包,整场安装作废。现在自动换官方源重来一次。
  • 同一个插件装两遍会多出一行,窗口里同一插件列两次。现在会说"已经装着";链接断了则只重指链接,不动配置。
  • 窗口看不见 Agent 发起的下载。现在看得见,而且和你自己点的是同一块东西。
  • 时间显示的是 UTC 不是你的时区。22:11 起的下载曾写成 14:11,日志文件名也差八小时。现在日志、文件名、沙箱名全跟着系统时区走。

In English —— plugins from npm now install, and actually boot.

Most third-party plugins on npm ship without their official dependencies; installed through dsh-box, such a package used to make dsh refuse its whole plugin tree. This release fixes that at the root: one download, and each dsh release gets its own version-matched shelf of official parts beside it, so a sandbox stays correct whichever release boots it. Installing into your daily cabinet copies the whole thing in, so your own dsh loads it and deleting dsh-box costs nothing.

A full round-trip run afterwards turned up six more problems, all fixed here: two concurrent installs corrupting the package tree; a single 404 from a mirror throwing away the whole install; installing the same plugin twice adding a duplicate row; the window unable to see a download an agent started; and every timestamp being UTC pretending to be local time.