@treeport/treeport 0.5.0 → 0.7.0

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.
@@ -71,6 +71,34 @@
71
71
  "when": 1786800000000,
72
72
  "tag": "0009_open_folders",
73
73
  "breakpoints": true
74
+ },
75
+ {
76
+ "idx": 10,
77
+ "version": "6",
78
+ "when": 1787565462059,
79
+ "tag": "0010_browser_panels_and_permissions",
80
+ "breakpoints": true
81
+ },
82
+ {
83
+ "idx": 11,
84
+ "version": "6",
85
+ "when": 1787939530241,
86
+ "tag": "0011_free_magdalene",
87
+ "breakpoints": true
88
+ },
89
+ {
90
+ "idx": 12,
91
+ "version": "6",
92
+ "when": 1788000000000,
93
+ "tag": "0012_terminal_host_cutover",
94
+ "breakpoints": true
95
+ },
96
+ {
97
+ "idx": 13,
98
+ "version": "6",
99
+ "when": 1788100000000,
100
+ "tag": "0013_workspace_item_order",
101
+ "breakpoints": true
74
102
  }
75
103
  ]
76
104
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@treeport/treeport",
3
- "version": "0.5.0",
3
+ "version": "0.7.0",
4
4
  "description": "A tree-first terminal driver for persistent development workspaces.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -35,23 +35,29 @@
35
35
  "access": "public"
36
36
  },
37
37
  "dependencies": {
38
- "@hono/node-server": "^2.0.10",
39
- "@hono/zod-validator": "^0.9.0",
38
+ "@effect/opentelemetry": "^0.64.0",
39
+ "@effect/platform": "^0.97.1",
40
+ "@effect/platform-node": "^0.108.1",
41
+ "@effect/rpc": "^0.76.2",
40
42
  "@libsql/client": "^0.17.4",
43
+ "@opentelemetry/sdk-trace-base": "^2.11.0",
44
+ "@opentelemetry/sdk-trace-node": "^2.11.0",
45
+ "@playwright/cli": "0.1.18",
41
46
  "@radix-ui/react-context-menu": "^2.3.7",
42
47
  "@vitejs/plugin-react": "5.2.0",
43
- "@xterm/headless": "^6.0.0",
48
+ "@xterm/addon-serialize": "0.15.0-beta.301",
49
+ "@xterm/headless": "6.1.0-beta.303",
50
+ "cmdk": "^1.1.1",
44
51
  "commander": "14.0.3",
45
52
  "drizzle-orm": "^0.45.2",
46
- "effect": "^3.22.0",
47
- "hono": "^4.11.7",
53
+ "effect": "^3.22.1",
48
54
  "jsonc-parser": "^3.3.1",
49
55
  "node-pty": "1.2.0-beta.14",
50
- "socket.io": "4.8.3",
51
- "socket.io-client": "4.8.3",
56
+ "playwright": "1.61.1",
52
57
  "vite": "8.1.5",
58
+ "ws": "^8.21.1",
53
59
  "zod": "^4.3.6",
54
- "@treeport/panel-sdk": "0.5.0"
60
+ "@treeport/panel-sdk": "0.7.0"
55
61
  },
56
62
  "devDependencies": {
57
63
  "@fontsource-variable/inter": "^5.2.8",
@@ -68,9 +74,11 @@
68
74
  "@tanstack/react-router": "^1.170.18",
69
75
  "@types/react": "^19.2.10",
70
76
  "@types/react-dom": "^19.2.3",
71
- "@xterm/addon-fit": "^0.11.0",
72
- "@xterm/addon-web-links": "^0.12.0",
73
- "@xterm/xterm": "^6.0.0",
77
+ "@types/ws": "^8.18.1",
78
+ "@xterm/addon-fit": "0.12.0-beta.301",
79
+ "@xterm/addon-image": "0.10.0-beta.301",
80
+ "@xterm/addon-web-links": "0.13.0-beta.301",
81
+ "@xterm/xterm": "6.1.0-beta.304",
74
82
  "class-variance-authority": "^0.7.1",
75
83
  "clsx": "^2.1.1",
76
84
  "drizzle-kit": "^0.31.10",
@@ -89,7 +97,7 @@
89
97
  "build:node": "tsdown",
90
98
  "build:web": "vite build",
91
99
  "check:package": "node scripts/check-package.mjs",
92
- "test:package": "node scripts/smoke-package.mjs",
100
+ "test:package": "node scripts/smoke-package.mjs && node scripts/smoke-upgrade.mjs",
93
101
  "dev": "node scripts/development.mjs",
94
102
  "dev:server": "rm -rf .treeport-dev-dist && TREEPORT_DATA_DIR=.treeport-dev/data TREEPORT_RUNTIME_DIR=.treeport-dev/runtime TREEPORT_DAEMON_LIFECYCLE=external tsdown --watch --out-dir .treeport-dev-dist",
95
103
  "start": "TREEPORT_WEB_DIST=dist/web node dist/node/server/index.js",
@@ -1,12 +1,14 @@
1
1
  ---
2
2
  name: treeport
3
- description: Understand Treeport-managed terminal context and safely create persistent, observable terminals and child trees with the Treeport CLI. Use when an agent or extension needs to inspect its Treeport environment, open another session, or spawn work in a separate tree.
3
+ description: Detailed Treeport CLI guidance for child-tree orchestration, lifecycle, services, remote access, updates, and recovery. Use when compact Pi guidance or command help is not sufficient. Do not load for routine background processes or browser tabs in a managed Pi session.
4
4
  compatibility: Requires the treeport CLI on PATH and a reachable Treeport daemon. Creation commands also require the requested child executable to be installed.
5
5
  ---
6
6
 
7
7
  # Treeport
8
8
 
9
- Treeport is a generic terminal and tree layer. Its terminals are persistent tmux sessions that appear in the Treeport UI. A user can open a created terminal, take control of the normal application TUI, and continue working in the same session.
9
+ In a managed Pi session, use the injected CLI guidance for routine terminal and browser operations. Load this skill only when you need more detail.
10
+
11
+ Treeport is a generic terminal and tree layer. Its persistent terminals are owned by Treeport's detached terminal host and appear in the Treeport UI. A user can open a created terminal, take control of the normal application TUI, and continue working in the same session.
10
12
 
11
13
  Treeport does not define task sources, planning or approval states, agent tool policies, or provider-specific workflows. The caller owns names, commands, prompts, and higher-level orchestration.
12
14
 
@@ -21,7 +23,7 @@ Treeport does not define task sources, planning or approval states, agent tool p
21
23
  - When the lifecycle is `external`, never run `treeport start`, `treeport stop`, or `treeport remote enable`.
22
24
  - In the external lifecycle, the parent process owns startup, shutdown, and remote exposure.
23
25
  - When the lifecycle is `service`, normal `start` and `stop` delegate to the OS manager.
24
- - Use bare `treeport update` to update a supported local npm installation. It preserves tmux terminals and an enabled service, and restarts only a daemon that was running.
26
+ - Use bare `treeport update` to update a supported local npm installation. It preserves hosted terminals and an enabled service, and restarts only a daemon that was running.
25
27
  - Never run bare `treeport update` for an external or selected remote daemon.
26
28
  - Never invoke `sudo` for a normal service or update operation.
27
29
  - Normal macOS service mode is a user/login LaunchAgent and does not need an administrator.
@@ -37,7 +39,7 @@ Run:
37
39
  treeport context
38
40
  ```
39
41
 
40
- Inside a managed terminal, this reports the current project, tree, terminal, paths, statuses, IDs, and daemon URL. It reports whether Treeport, the OS service, or an external process manages the daemon lifecycle. It resolves the injected IDs strictly. It does not guess identity from the current path.
42
+ Inside a managed terminal, this reports the current project, tree, terminal, paths, statuses, IDs, tree context values, and daemon URL. User-supplied context can contain an issue identifier, a task description, or other information for the tree. Use these values as task input when the caller asks you to work from the tree context. It reports whether Treeport, the OS service, or an external process manages the daemon lifecycle. It resolves the injected IDs strictly. It does not guess identity from the current path.
41
43
 
42
44
  Outside Treeport it reports that the terminal is not managed and exits successfully. `TREEPORT_API_URL` may be configured outside a managed terminal; if any context ID is present, however, all injected values are required. Partial IDs or IDs that no longer belong together fail instead of falling back to path inference.
43
45
 
@@ -59,7 +61,7 @@ Launch a program directly:
59
61
  treeport terminal create --worktree <tree-id> --name <terminal-name> -- <program> <arg> ...
60
62
  ```
61
63
 
62
- The command returns after Treeport creates the tmux session. The program continues independently of the browser and of the caller that created it.
64
+ The command returns after the detached terminal host creates the session. The program continues independently of the browser, API daemon, and caller that created it.
63
65
 
64
66
  ## Create a child tree and terminal
65
67
 
@@ -80,7 +82,7 @@ Treeport serializes tree mutations per project. If a caller needs several child
80
82
 
81
83
  ## Interpret creation results
82
84
 
83
- A successful `terminal create` means the tmux session was created. The requested program can still exit later.
85
+ A successful `terminal create` means the hosted terminal was created. The requested program can still exit later.
84
86
 
85
87
  `spawn` is intentionally non-atomic after Git creates the worktree:
86
88
 
@@ -133,6 +135,60 @@ treeport terminal wait <terminal-id> --until exit
133
135
 
134
136
  Treeport does not infer agent settlement. An orchestrator can inspect first, wait for `working` if no progress cycle has been observed, and then wait for `idle`. Progress depends on the child application emitting OSC `9;4`; for Pi, `terminal.showTerminalProgress` must be enabled. Applications should clear progress or refresh active progress more frequently than the five-minute lease. A null progress value is not proof that every application supports progress reporting.
135
137
 
138
+ ## Inspect the worktree application in a browser tab
139
+
140
+ The Browser primitive has one live runtime for each browser tab.
141
+
142
+ Electron owns the visible `<webview>` page for a local desktop connection.
143
+
144
+ Playwright controls managed Chromium for a web or remote desktop connection.
145
+
146
+ Never attach Treeport to a personal browser profile.
147
+
148
+ First, inspect the available browser tabs:
149
+
150
+ ```sh
151
+ treeport browser list
152
+ ```
153
+
154
+ If no browser tab is open, open one in the current tree:
155
+
156
+ ```sh
157
+ treeport browser open --worktree .
158
+ ```
159
+
160
+ Use these commands on the current live page:
161
+
162
+ ```sh
163
+ treeport browser snapshot
164
+ treeport browser click e12
165
+ treeport browser fill e14 "value"
166
+ treeport browser press Enter
167
+ treeport browser console
168
+ treeport browser network
169
+ treeport browser screenshot
170
+ ```
171
+
172
+ The commands select the only browser tab in the current tree.
173
+
174
+ When more than one browser tab exists, add `--panel <panel-id>`.
175
+
176
+ Snapshot references belong to one runtime generation.
177
+
178
+ Take a new snapshot after navigation or a runtime change.
179
+
180
+ A local desktop owner does not need managed Chromium.
181
+
182
+ If no local owner exists, check managed Chromium before daemon automation:
183
+
184
+ ```sh
185
+ treeport browser status
186
+ ```
187
+
188
+ Ask the user before you run `treeport browser install`.
189
+
190
+ Leave the browser tab open so the user can inspect the result.
191
+
136
192
  ## Automation and integrations
137
193
 
138
194
  Extensions and scripts should add `--json` before the `--` command separator: