Skip to content

Releases: 33moren33/dsh-box

v0.4.0

Choose a tag to compare

@33moren33 33moren33 released this 28 Aug 09:37

45 条命令收成十个动词;--version 现在也收文件夹;0.3.5 那个打不开的窗口修好了。

  • 十个动词,旧名一个不留。 ls get rm start stop set logs ui agent help,原先各自成命令的那些改成参数。这么做不是为了少几条,是因为一个只拿 --help 上手的 agent 会数出四个不同的「删」——那说明它得先学会我们内部有四层存储才动得了手。

    不兼容versionspulldropplugins add/installpackagesconfigpathstatusattach 这些名字都没了,脚本要改。换算最省事的办法是敲一次 dsh-box,那十行就是全部。

    ⚠️ 绿色版用户:0.3.5 公告里那句 dsh-box path add 现在叫 dsh-box set path on

  • 能起的 dsh 多了两种。 --version 除了版本号,也收一个文件夹:你自己从源码构建的那份,和某个自带 dsh 的应用。带斜杠就按文件夹读,版本号里不会有斜杠,所以一根轴仍然只有一个旗标。

    应用那种用它自带的解释器起(原生零件是按它的规格编的)。树一律认硬盘上摊着的真文件——整棵树封在归档包里的会当场拒绝并说清原因,而不是等两分钟再给你一句「找不到某个包」。钉版核对对别人的树只报告,不拦着:那棵树不是我们装的。

  • 0.3.5 的窗口在 Windows 上一次都打不开。 这一版修了。原因是程序动过控制台之后,再起子进程必须把三个输入输出句柄显式声明齐——少一个,系统就整体拒绝,而且不告诉你是哪一个。

  • 起失败不再留下没人认领的进程。 以前等待就绪超时之后,那台 dsh 其实还活着,而账本上是空的:停不掉、窗口里看不见,下次启动撞上一个被占的端口。现在它会把自己起的那台收掉,并告诉你收掉了。

    同一处还修好了就绪判据:新版 dsh 的首页要先认证,旧判据永远等不到「起好了」,会把一台健康的 dsh 报成启动失败。

数据目录格式没变,沙箱和下载的版本原地可用。


In English — forty-five commands became ten verbs, --version now takes a folder, and the window that never opened on Windows works again.

The ten are ls, get, rm, start, stop, set, logs, ui, agent and help; what used to be a command of its own is now an argument. The reason is not tidiness: an agent given nothing but --help counted four different verbs for "delete", which meant it had to learn that we keep four layers of storage before it could act at all. ⛔ This is a breaking change — versions, pull, drop, plugins add/install, packages, config, path, status and attach are gone, and scripts need updating. Typing dsh-box prints the whole new surface in ten lines. ⚠️ Portable users: the dsh-box path add from the 0.3.5 announcement is now dsh-box set path on.

Two more kinds of dsh can be started. Besides a release number, --version accepts a folder — one you built from source, or an application that ships its own dsh. A slash makes it a folder and a release number never has one, so the axis still has exactly one flag. An application is started with the interpreter shipped beside it, because its native parts are built for that runtime. The tree itself must always be real files on disk: one sealed inside an archive is refused immediately, with the reason, rather than failing two minutes later with a missing package. The pin check reports what it finds on somebody else's tree and does not refuse — that tree is not one we installed.

The 0.3.5 window never opened once on Windows; that is fixed. Once a program has touched the console, every process it spawns must declare all three standard handles explicitly — leave one out and the system refuses the whole call without saying which.

A failed start no longer leaves a process nobody owns. Previously, when the readiness wait timed out, the dsh was still running while the ledger held nothing: it could not be stopped, the window could not see it, and the next launch met a port held by something nobody admitted starting. It now stops what it started, and says so. The same fix taught the readiness check to authenticate: newer dsh guards its index page, and the old check could never see the finished page — reporting a healthy dsh as one that failed to start.

The data directory format is unchanged; existing sandboxes and downloaded releases keep working.

v0.3.5

Choose a tag to compare

@33moren33 33moren33 released this 27 Aug 06:27

exe 自己也成了命令行;「停止」按钮不再可能杀错进程;数据文件夹改了名。

  • dsh-box 现在是一个可以敲的词。 双击仍然是窗口,带参数就是命令行。⛔ 0.3.4 及更早的 exe 没有这张脸——带参数会挂住不返回,文件名也还叫 dsh-box-shell.exe

    绿色版要自己敲一次 dsh-box path add,之后在任何目录直接敲三个字;安装版装完会替你敲。

  • 「正在运行」不再只认一个进程号。 旧版把几天前记下的号码当身份,而机器重启之后那个号码可能已经属于别的程序——窗口照样给它画一个「停止」按钮,按下去杀掉的是陌生进程。现在启动时把进程的出生时刻一起记下,两样都对上才算同一台。

    与旧账本不兼容:更早版本起的沙箱,这一版停不掉,需要你手动结束。

  • 数据文件夹改叫 dsh-box-files,里面 boot 是程序、data 是你的家当,结构一个字没变。原因是它和可执行文件重名:在可执行文件不带扩展名的系统上,同一层不能既有这个名字的文件又有这个名字的文件夹。

安装向导同轮补上:可以选中文或英文,且向导选的语言就是装完之后的初始设置。

⚠️ 装过更早版本的话,安装器那一页的「卸载旧版」拦不住——选请勿卸载照样装,装完会把登记整条覆盖成新的。


In English —— the exe is a command line of its own now, the stop button can no longer kill a stranger, and the data folder has a new name.

Double-click still opens the window; pass arguments and the same file answers on the terminal. The portable build needs one dsh-box path add before the word works from any directory; the installer does that for you. A sandbox is now identified by (pid, start time) instead of a bare pid, because a pid recorded days ago may belong to a stranger after a reboot; ledgers written by earlier versions are not compatible, so their sandboxes must be stopped by hand. The data folder is now dsh-box-files — same boot and data inside — because a folder sharing the executable's name cannot sit beside it on any platform whose executables carry no extension.

v0.3.4

Choose a tag to compare

@33moren33 33moren33 released this 23 Aug 17:10

修掉 0.3.3 自己带出来的一处倒退,并给卡死的下载装上超时与取消。

0.3.3 发出去四小时后,我们照着它自己的公告,从 npm 装了一个依赖较多的聚合插件包,当场撞上四件事——第一件是那一版新引入的。

  • 换源重试原来对任何失败都触发,第一次真上场就把跑了 23 分钟的安装从头再来。而那次其实是被中断的,npm 一个字都没输出,真正卡住的是某个依赖的安装脚本在连 GitHub——换哪个源都救不了。现在只在 npm 明说 E404ETARGET 时才换源。
  • 下载有了 15 分钟总超时,到点连它起的所有子进程一起结束。真正卡住的往往不是 npm 自己,是它子孙里某个 postinstall 在下二进制。
  • 新增 packages cancel,窗口上也有「停止下载」按钮。此前停一个卡死的安装只能去 shell 里 taskkill
  • 进度不再只是一个计时器:会一并报包树里已经落盘多少个包,安装脚本自己的输出也透出来了。

⚠️ 装第三方插件时,npm 会连带执行它依赖里的安装脚本,其中可能有从境外拉可执行文件的。国内网络下这是最容易卡住的一步——卡了就 packages cancel,或等 15 分钟自动结束。


In English —— fixes a regression 0.3.3 introduced, and gives a stuck download a timeout and a stop button.

The registry retry added in 0.3.3 fired on any npm failure; the first time it ran for real it threw away a 23-minute install to start over, when the actual blocker was a dependency's install script reaching an unreachable host. It now retries only when npm says E404/ETARGET. Downloads get a 15-minute cap that ends the whole process tree, a new packages cancel command with a matching button in the window, and a progress line that reports how many packages have landed rather than only counting seconds.

v0.3.3

Choose a tag to compare

@33moren33 33moren33 released this 23 Aug 15:37

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.

v0.3.0

Choose a tag to compare

@33moren33 33moren33 released this 23 Aug 05:36

这一版最要紧的一件事,跟 dsh-box 无关,但每个 Windows 用户都该知道。

Windows 上有几段 Node 删不掉、拷不动带中文的路径

不是本工具的缺陷,是 Node 自己的(#61067#61878)。递归删除和递归拷贝,只要路径里有中文、日文、重音字母或 emoji,就回报成功、什么都没做,有时直接让进程崩掉。

上一版 0.2.0 的产物上能原样复现:建一台叫「中文测试」的沙箱,rm 它,得到 {"ok":true}、退出码 0、沙箱还在磁盘上

这一版已经绕开,在下面每一段版本上都正常。

正常 有缺陷
20.x、21.x 22.17 – 22.21(现行 LTS,至今未修)
22.0 – 22.16 23.x 全线
24.15 或更新 24.0 – 24.14
25.9 或更新、26.x 25.0 – 25.8

每一格都是下载那一版真跑出来的。只在 Windows 上,Linux 与 macOS 不受影响。

两个调用是两个不同的 bug、不同版本修的——删除修在 24.13.1,拷贝修在 24.15.0。只看删除那一行会以为「退回 22 LTS 就安全」,那是错的:22 线从 22.17 起拷贝就坏,至今没修。没有一个在维护的 LTS 是干净的。

用户名是「张三」或 José 的人,路径里到处都是这类字符。要一个干净的,装 24.15 或更新。

批准改成「窗口起的才算」

--approved 从一句恳求变成一条判据:这次运行的父进程是不是那个配置窗。窗口执行任何动作都是它起一个命令行子进程,所以「父进程是窗口」就是「有人点过头」的证据。你自己带上旗标过不去,agent 带上也过不去。

config ask-on-daily off 的含义同时收窄成「窗口别问我第二遍」——它不再给命令行那一侧开门。一个人为自己少点一次而勾的框,不该变成机器上任何东西的通行证。

一个数据目录,一个配置窗

双击两次桌面版,不再开出两个壳、两个服务、两个指着同一个数据目录的窗口。第二次会说清楚第一个开在哪儿。

规则只写了一份:壳带 --json 起命令行,认 UI_ALREADY_SERVING 这个 code,Rust 那边不抄第二份判断。

其余

同名沙箱并发:两条 start --sandbox <同一个名字> 同时发,只有一条真的起 dsh,另一条明说被拦下的原因。启动前先独占占位,不再等起完了才记账。

登录凭证三态:跟插件那套一致——绿钩是已有、蓝是这次导入、取消勾是这次拿掉。新增 signin / signout。日常档案柜那份是硬闸门,不备份。

回看也画框:可以点到某一步,那一步动过的控件重新亮起来;当时删掉的东西给虚线占位。

--json 里的 places 改成给身份plugins rm 被拦下时,它原来给的是翻译过的档案柜名字,于是同一个拒绝在中文机器和英文机器上返回不同的值。现在给 {sandbox, main}sandboxnull 就是日常档案柜。

验收

npm test 现在 242 项,自己造一次性数据目录、跑完删掉,用几十行的 dsh 替身,不下包、不联网、不碰你真实的 ~/.dsh

新加一道 check-no-recursive-fs全仓禁止直接调用递归的 rmSync / cpSync,新代码白白继承这条规则,不必有人记得。删除与拷贝各带一个对照组,跑的就是内建那两个调用——它们哪天开始通过,就是 Node 修好了、这套绕法可以整个删掉的信号。

本版在 Linux(aarch64 + musl) 上跑过 240 项,零不通过(差的两条正是只在 Windows 上成立的对照组)。

下载

桌面版、便携包、.dmg.deb.AppImage 都在下方资产里,或者不装直接跑:

npx dsh-box@0.3.0 ui

macOS 的 .dmg 仅 Apple Silicon。macOS 与 Linux 的安装包仍未有人实跑过,遇到问题请开 issue。


English

The most important thing in this release has nothing to do with dsh-box, and every Windows user should know it.

Some Node versions cannot delete or copy non-ASCII paths on Windows

A defect in Node itself, not in this tool (#61067, #61878). Recursive delete and recursive copy, given a path holding an accented letter, Chinese, Japanese or an emoji, report success and do nothing — and on some shapes they take the process down. It reproduces on the 0.2.0 artifacts as shipped: create a sandbox named 中文测试, rm it, and get {"ok":true}, exit code 0, and the sandbox still on disk.

This release works around both, so it behaves the same on every version below.

Fine Defective
20.x, 21.x 22.17 – 22.21 (the current LTS, still unfixed)
22.0 – 22.16 the whole 23 line
24.15 or newer 24.0 – 24.14
25.9 or newer, 26.x 25.0 – 25.8

Every cell was measured by downloading that version and running it. Windows only.

They are two bugs fixed in two different versions — the delete in 24.13.1, the copy in 24.15.0. Reading only the delete row suggests falling back to the 22 LTS is safe. It is not: the copy has been broken there since 22.17 and still is. No maintained LTS line is clean. For a clean one, install 24.15 or newer.

Approval means "started by the window"

--approved stopped being a request and became a test: is the parent process of this run the config window? Every action the window performs spawns a command-line child, so "the parent is the window" is the evidence that a person was present. Passing the flag yourself does not get through, and neither does an agent passing it. config ask-on-daily off now means only "the window need not ask me twice" — it no longer opens the command-line door.

One data directory, one config window

Double-clicking the desktop build twice no longer produces two shells, two services and two windows pointing at the same data directory; the second one says where the first is. The rule exists once: the shell runs the command line with --json and recognises the UI_ALREADY_SERVING code, rather than keeping a second copy of the rule in Rust.

Also

Concurrent same-name sandboxes: two start --sandbox <same name> at once now start exactly one dsh, and the other says why it was held back — the claim is taken before launching, not recorded after.

Sign-in credentials are tri-state, matching plugins: green means present, blue means importing now, unticking means removing now. New signin / signout. The daily cabinet's copy is a hard gate and is never backed up.

The recall is framed too: click any step and the controls it touched light up again; whatever it deleted gets a dashed placeholder.

places in --json now carries identity, not prose. When plugins rm is refused it used to return the translated name of the daily cabinet, so the same refusal answered differently on a Chinese and an English machine. It is now {sandbox, main}, with sandbox: null meaning the daily cabinet.

Verification

npm test is now 242 checks against a throwaway data directory and a small dsh stub — no downloads, no network, and it never touches your real ~/.dsh. A new check-no-recursive-fs forbids calling recursive rmSync / cpSync anywhere in the repository, so new code inherits the rule for free. Delete and copy each keep a control group running the built-in call: when those start passing everywhere, Node has been fixed and the whole workaround can go. This release also passes 240 checks on Linux (aarch64 + musl), the two missing ones being the controls that only hold on Windows.

Installers for all three platforms are in the assets below, or run it without installing: npx dsh-box@0.3.0 ui. The .dmg is Apple Silicon only.

v0.2.0 —— 命令行成为本体,Agent 可以驾驶

Choose a tag to compare

@33moren33 33moren33 released this 23 Aug 00:43

这一版是从命令行出发的一次重构,也是目前最大的一次升级。 工具从「一个带界面的启动器」变成了「一个 Agent 能驾驶、人看得见的命令行工具」。

一个本体,两个视图

上一版有两套门面:窗口一套逻辑,命令行一套逻辑,同一件事写了两遍。它们悄悄跑偏过——命令行起的沙箱,窗口当它不存在。

现在窗口是命令行的另一种视图:读走磁盘,写走命令。窗口每按一个按钮,都是起一个进程去敲你也能敲的那条命令。窗口没有任何命令行没有的能力,唯一的例外是「打开一个链接」,那不是对本工具拥有的东西做动作。

判据一句话:窗口关掉再打开,不丢任何东西。

Agent 可以驾驶,你看得见每一步

dsh-box attach          # 我来开车
dsh-box detach          # 交还
dsh-box memory          # 上次接管期间做了什么(含被拒绝的)
dsh-box history         # 这个数据目录里做过的所有事

attach 之后,配置窗顶上出现一条蓝带,即将被动到的控件挂上编号,页面下方就地展开一份命令轨迹——每一步都渲染成你可以照着重跑的那行命令。做完了、被拒了、拒的理由是什么,都在上面。

锁在服务端,不在页面上。 Agent 开车期间,窗口发出的一切命令由服务端直接拒绝,只放行「停止并收回」。页面上的置灰因此退化成纯装饰:标错一个控件,最坏是它看起来能点、点了给句说明,再也变不成损害。

命令行本来就是给 Agent 准备的:有 --help,任何命令加 --json 就以 JSON 回话,失败也是 JSON,且带一个不会变的 code。所以这里不做常驻 HTTP API、也不做 MCP。

中英双语内置,随时切

dsh-box config lang en

语言是这个数据目录的设置,不是页面偏好:命令行与配置窗一起变,帮助、错误、界面全盖。窗口右上角那个开关背后跑的就是这条命令——所以窗口仍然没有多出能力。没设过就跟系统语言走。

错误 code、旗标与命令名、写进你文件里的标记,永不翻译:它们是数据,不是话。

插件改成了档案柜的属性

不是「这次启动的选项」。插件装进哪个档案柜,就写进那个档案柜自己的配置,你自己敲 dsh 一样加载--plugin 是加、--unplug 是减、不写就是什么都不改;想要纯官方的 dsh 就新建一个沙箱。

本地文件夹和 npm 上的包都能装。每次改动前先备份,plugins restore 整份还原;卸载要逐字节回到原样,是 hash 对,不是肉眼对。

两个词定案了

是什么
档案柜 一个 DSH_HOME。装对话、配置、登录。--sandbox--main 说的都是它
工作区 dsh 干活的那个项目文件夹。这是 dsh 官方的叫法

此前版本里的「工作区」多半指的是档案柜,命令行、帮助与界面已全部按新口径改过。

新增的命令

packages(看 dsh-box 替你下载的插件包、删、清没人用的)/history(持久操作记录)/workspaces(这个档案柜下次打开哪个项目文件夹)/plugins backups rm | pruneconfig reset(设置文件读坏时的逃生口)/quit(总退出)/adopt --from --to(对话在档案柜之间复制)。

修掉的两个真问题

新沙箱装任何一个插件,就再也起不来。 dsh 给新 profile 写的配置以 [] 结尾,我们在后面追加就成了第二份 YAML 文档,dsh 整份拒绝解析。Windows 与 Linux 同样中招。

两条 start --new 同时发,只造出一台沙箱。 取名是「先查后用」,两个进程查到同一个名字,于是两台 dsh 压在同一个档案柜上。

另外:某些环境(musl、Nix 编译的 Node、部分 arm64)上根本起不了 dsh,现在按「问这台 Node 自己能不能拿到内部加载器」来判断,而不是按平台猜。

验收

npm test 十一套,自己造一次性数据目录、跑完删掉,用几十行的 dsh 替身,不下包、不联网、不碰你真实的 ~/.dsh。本版在 Linux(aarch64 + musl) 上第一次实测通过。

下载

桌面版、便携包、.dmg.deb.AppImage 都在下方资产里,或者不装直接跑:

npx dsh-box@0.2.0 ui

macOS 的 .dmg 仅 Apple Silicon。macOS 与 Linux 的安装包仍未有人实跑过,遇到问题请开 issue。


English

This release is a refactor that starts from the command line — the largest upgrade so far. The tool went from "a launcher with a window" to "a command-line tool an agent can drive while you watch."

One thing, two views. The previous version implemented every action twice, once in the window and once in the command line, and the two drifted: a sandbox started from the command line did not exist as far as the window was concerned. Now reads go to disk and writes go through a command — every button starts a process and runs the command you could have typed. The window has no capability the command line lacks. The test: close the window, open it again, and nothing is lost.

An agent can drive. attach / detach / memory / history. While an agent drives, a blue band crosses the top of the window, touched controls are numbered, and a trail of re-runnable commands unfolds below — what was done, what was refused, and why. The lock lives in the server, not on the page: every command the window sends is refused outright, only "stop and take back control" gets through. Greying-out is therefore decoration, and a mislabelled control can no longer become damage.

English is built in. config lang en — the language is a setting of the data directory, so the command line and the config window change together, help and errors included. Error codes, flags, command names and the markers written into your own files are never translated: they are data, not speech.

Plugins belong to the cabinet, not to the launch. Installed into a cabinet they stay, so typing dsh yourself loads them too. Local folders and npm packages both work; every change is backed up and uninstalling returns the file byte for byte, verified by hash.

Two words settled: a cabinet is one DSH_HOME (conversations, config, sign-in); a workspace is the project folder dsh works in, which is dsh's own term.

New commands: packages, history, workspaces, plugins backups rm | prune, config reset, quit, and adopt --from --to.

Two real bugs fixed: installing any plugin into a fresh sandbox made it unable to start ever again (our block turned the profile patch into a second YAML document, which dsh refuses wholesale); and two concurrent start --new produced only one sandbox, leaving two dsh processes on one cabinet. Also, environments where dsh could not start at all (musl, Nix-built Node, some arm64) are now detected by asking that Node whether it can reach the internal loader, rather than by guessing from the platform.

Verification: npm test runs eleven suites against a throwaway data directory and a small dsh stub — no downloads, no network, and it never touches your real ~/.dsh. This release is the first verified on Linux (aarch64 + musl).

Installers for all three platforms are in the assets below, or run it without installing: npx dsh-box@0.2.0 ui. The .dmg is Apple Silicon only. Nobody has yet run the macOS and Linux packages in anger — please open an issue if something breaks.

v0.1.2 —— 数据跟着程序走

Choose a tag to compare

@33moren33 33moren33 released this 21 Aug 01:59

解压在哪,数据就长在哪。 这一版把工具做成了它本来该有的样子:一个绿色软件。

数据跟着程序走

此前不管你是解压便携包还是装安装包,数据都偷偷写进了 %APPDATA%——看得见的文件夹里空空如也,真正的几百 MB 在另一个你没打开过的地方。现在不这样了。

exe 旁边只有一个 dsh-box 文件夹,里面装两样:boot 是程序,data 是你的家当(下载的版本、所有沙箱、日志)。覆盖解压就是升级——boot 换新,data 一个字不动。卸载器也只删它自己装进来的东西。只有当 exe 待在写不进去的地方(比如 Program Files),数据才退到你的用户目录。

npx 和从源码跑的路径同理:数据建在你当前所在目录下的 dsh-box/data

数据夹顺带改了名,不再叫 dsh_box——它和产品名只差一横一杠,谁看谁绕。

同一个沙箱不会被开起两台

「正在运行」这本账以前记在窗口进程的内存里,于是命令行起的沙箱窗口看不到,反过来也一样,同一个沙箱能被两边各开一台、抢同一个 DSH_HOME。现在账本落在磁盘上,用之前先验一遍那个进程还活着没有——窗口和命令行看到的是同一份状态。

便携包

Release 资产里多了一个 _x64-portable.zip。解压出来顶层就两样:exe 和 dsh-box,双击即用,不写注册表也不碰系统目录。

从 0.1.0 / 0.1.1 升上来的话

新版按新名字找数据,所以你已经下载的版本和沙箱会「不见」。它们没丢,把老文件夹改个名就回来了:

  • npx 或源码跑的:把 dsh_box 移进新建的 dsh-box 文件夹里,改名 data
  • 装了桌面版的:老数据在 %APPDATA%\com.dshbox.desktop\dsh_box,把它改名成 data 即可。

嫌麻烦也可以不动它,直接告诉工具老地方在哪:--box <目录>,或者设环境变量 DSH_BOX_HOME

下载

桌面版与便携包在下方资产里,或者不装直接跑:

npx dsh-box@0.1.2 ui

macOS 的 .dmg 仅 Apple Silicon。macOS 与 Linux 的安装包仍未有人实跑过,遇到问题请开 issue。

v0.1.1 —— 官方稳定版上起不来的修复

Choose a tag to compare

@33moren33 33moren33 released this 20 Aug 11:43

如果你装了 0.1.0 却起不来沙箱,就是这个版本修的。

修了三处

在官方稳定版上根本起不来。 启动 dsh 时我们固定加了一个 --no-open 参数,而它只有 rc.8 才有;rc.6 和 rc.7 收到就直接报错退出。偏偏工具自己推荐的、npm 上标着稳定版的,正是 rc.7——照着说明走的人第一次启动必然失败。命令行、配置窗、--main 三个入口都受影响。

代价要说清楚:现在不再阻止 rc.8 自己开浏览器,所以在 rc.8 上每启动一台沙箱会自动弹一个标签页。

配置窗现在只接受自己那张页面的请求。 它是个能启动进程、删除沙箱的本地服务,端口固定、代码公开,此前任何网页都能跨源向它发指令。现在三道检查:地址必须是本机窗口、来源若存在必须同源、每个接口调用必须带上本次启动随机生成的通行证。挡的是「配置窗开着时误访恶意网页」;已经在你电脑上以你身份运行的程序挡不住,也不必挡——它不需要绕过本工具。

版本体积不再永远显示 0MB。 版本目录比 npm 写下第一个文件早一分多钟建好,刷新若落在这段空窗期就会量到 0,并当成「装好的版本不会再变」永久记住。现在把测量时的包数一并记下,对不上就重新量。老的记录会自动作废重量,不用手动清理。

下载

桌面版在下方资产里,或者不装直接跑:

npx dsh-box@0.1.1 ui

macOS 的 .dmg 仅 Apple Silicon。macOS 与 Linux 的安装包尚未有人实跑过,遇到问题请开 issue。

v0.1.0

Choose a tag to compare

@33moren33 33moren33 released this 20 Aug 08:36

第一个版本。选一个官方 dsh 版本、勾几个本地插件,开一台隔离的 dsh 来试,你天天用的那台不受影响。

下载

平台 文件 说明
Windows dsh-box_0.1.0_x64-setup.exe 安装器,简体中文
macOS dsh-box_0.1.0_aarch64.dmg 仅 Apple Silicon,experimental
Linux dsh-box_0.1.0_amd64.AppImage experimental
Linux dsh-box_0.1.0_amd64.deb experimental

运行需要

本机 Node 20 或更新。 工具和 dsh 本身都是 Node 程序,缺了会弹窗指引你去装。

「沙箱」是什么

一个独立的 DSH_HOME,不是安全隔离。 权限和你日常那台 dsh 一模一样,隔开的是版本、插件、配置和对话,不是这台电脑。

已知事项

  • macOS 包未签名,首次打开要右键 →「打开」,否则会被 Gatekeeper 拦下。
  • macOS 与 Linux 的包由 CI 构建、未经实测,所以标 experimental。
  • Linux 的 .deb 依赖系统 WebKitGTK;AppImage 基本自带。