@devrouter/cli 0.0.30 → 0.0.31
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +43 -11
- package/dist/devrouter.js +1079 -272
- package/package.json +2 -1
- package/upgrade-prompts/0.0.31.md +23 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@devrouter/cli",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.31",
|
|
4
4
|
"description": "Local dev routing CLI with shared Traefik reverse proxy",
|
|
5
5
|
"author": "Roland Schlaefli",
|
|
6
6
|
"homepage": "https://github.com/rschlaefli/devrouter#readme",
|
|
@@ -55,6 +55,7 @@
|
|
|
55
55
|
"test:watch": "vitest",
|
|
56
56
|
"routing:smoke": "./scripts/smoke-routing.sh",
|
|
57
57
|
"devcontainer:smoke": "./scripts/smoke-devcontainer.sh",
|
|
58
|
+
"workspace:lifecycle-smoke": "./scripts/smoke-workspace-lifecycle.sh",
|
|
58
59
|
"bench:startup": "zsh -lc 'set -euo pipefail; echo \"=== dev --help (x5) ===\"; for i in {1..5}; do /usr/bin/time -p node dist/devrouter.js --help >/dev/null; done; echo \"=== dev app add --help (x5) ===\"; for i in {1..5}; do /usr/bin/time -p node dist/devrouter.js app add --help >/dev/null; done; echo \"=== dev status --json (x3, best effort) ===\"; for i in {1..3}; do /usr/bin/time -p node dist/devrouter.js status --json >/dev/null || true; done'",
|
|
59
60
|
"typecheck": "tsc --noEmit",
|
|
60
61
|
"bootstrap": "pnpm install && pnpm install:local",
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# Upgrade to devrouter 0.0.31
|
|
2
|
+
|
|
3
|
+
## What changed
|
|
4
|
+
|
|
5
|
+
Devrouter now persists managed-workspace ownership in the consumer repository's Git common directory. `workspace ls` classifies owners as `present`, `missing`, `locked`, or `conflict`; `workspace stop` pauses exact runtime/routes without removing the checkout; full `workspace down` fails before side effects for dirty or locked worktrees; and `workspace gc` reports cleanup candidates without mutation unless `--yes` is supplied.
|
|
6
|
+
|
|
7
|
+
The ambiguous `workspace down --keep-devpod` flag was removed. Normal config, app, status, and doctor commands still work outside Git, but the `workspace` command group now requires a Git repository.
|
|
8
|
+
|
|
9
|
+
## Steps
|
|
10
|
+
|
|
11
|
+
1. Install `@devrouter/cli@0.0.31` on the host and bump `.devrouter.yml` to `devrouter.version: 0.0.31`.
|
|
12
|
+
2. Run `devrouter repo agents --repo <repo>` to refresh the generated `AGENTS.md` section and bundled devrouter skill.
|
|
13
|
+
3. In every existing managed linked worktree, run `devrouter workspace ensure .` once. This validates the exact DevPod/path and adopts it into the durable owner ledger.
|
|
14
|
+
4. Replace `workspace down --keep-devpod` automation. Use `workspace stop <workspace>` to pause runtime/routes while retaining checkout and data, or `workspace down <workspace> --keep-worktree` to delete runtime/routes while retaining the checkout and owner record. There is no supported mode that removes a worktree while leaving its DevPod running.
|
|
15
|
+
5. If the repository uses the managed devcontainer scaffold, run `devrouter repo devcontainer write --dry-run --json`, review the plan, then apply it with `--yes`. Custom linked-worktree overlays must pass `WORKSPACE` and `DEVROUTER_WORKSPACE` into the app and mount `DEVROUTER_GIT_COMMON_DIR` at the same absolute path.
|
|
16
|
+
6. Run `devrouter workspace gc --repo <repo> --json` and review every eligible candidate in the dry-run report. Add `--yes` only when every eligible candidate is approved, because apply cleans all eligible candidates in the repository scope; legacy, locked, present, and conflicting evidence is never mutated.
|
|
17
|
+
|
|
18
|
+
## Verify
|
|
19
|
+
|
|
20
|
+
- `devrouter workspace ls --repo <repo> --json` shows expected owner, DevPod, route, path, and branch evidence.
|
|
21
|
+
- A dirty linked worktree rejects full `workspace down` without stopping its DevPod or removing routes.
|
|
22
|
+
- `devrouter doctor --repo <repo> --json` reports one `workspace.ownership-cleanup` check and an exact GC command when review is needed.
|
|
23
|
+
- A non-Git folder with `.devrouter.yml` still supports `devrouter app ls`, `devrouter repo inspect`, and `devrouter doctor`; workspace commands return the clear Git-required error.
|