bin/delete.js — staged removal + branch tombstonebe delete as JS: stage a file's removal (dirty-gate → unlink → delete row),
bare-sweep vanished tracked files, dir recursive-unlink, and the ?br branch
tombstone. Reuses JS-049's stage.js. ← JS-047+JS-048+JS-049. Part of
JS-046. Method: Issues.
sniff/DEL.c: named delete refuses DELDIRTY if mtime ∉ stamp-set
(:492), then FILEUnLinks (:500), then appends delete <path> (no file
stamp). Bare delete sweeps baseline files gone from disk (del_sweep_missing
:307); dir-form is preflight-then-unlink (del_dir :210).?br→DELBranch tombstone ?br → 000…0 (:736); refuses trunk / wt-on-branch
/ active descendants unless -r (deepest-first, :664).bin/delete.js: path/dir/bare staging (reuse stage.js), branch tombstone via
store.tombstone (JS-048) with the trunk / on-branch / -r guards.be delete. DELETE physically
unlinks BEFORE logging — back the dirty-gate with classify.wtEqBase (content,
not just mtime) so a user's edits are never silently removed.test/js/delete/*: file / dir / bare-missing / branch
tombstone (+ -r) — JS vs native be delete: rows, unlinked files, REFS.
(Now be/test/delete/*: file/dir/dirty/bare-missing/branch/branch-recursive
/nonexistent, 8 cases.)e0f79ff0.)e0f79ff0 (bin/delete.js + shared reanchor test helper). Today at
be/verbs/delete/delete.js (beagle-ext shard), staging via
be/shared/stage.js; parity suite be/test/delete/*. Audited 2026-07-07.