dsh-localdesk 0.4.2 → 0.14.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.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,20 @@
2
2
 
3
3
  All notable changes to this package. Format follows [Keep a Changelog](https://keepachangelog.com/), versions follow SemVer.
4
4
 
5
+ ## 0.14.0 - 2026-12-02
6
+
7
+ ### Changed
8
+
9
+ - DSH Session groups use DSH's own short title (`sessionTitle.get`) first, then the goal objective, then `cwd · time`.
10
+ - MyFlicker groups by workspace and titles each Session with its first real user message; only the last seven days are considered and each workspace keeps at most eight idle Sessions. Codex and Claude Code group by project.
11
+ - `readState` coalesces concurrent callers (single-flight), so the 3-second snapshot, the open desk and the island share one scan.
12
+ - The external pill width adapts to its metrics and turns amber when anything needs review; the in-page island refreshes immediately when the window regains focus.
13
+ - The files source skips `~/.claude` while the Claude Code adapter is present.
14
+
15
+ ### Fixed
16
+
17
+ - Four confirmed bugs: Antigravity app open, the missing `changed` label, group/row kind labels, and `undefined` snapshot ids.
18
+
5
19
  ## 0.4.1 - 2026-11-23
6
20
 
7
21
  ### Added
@@ -18,6 +32,176 @@ All notable changes to this package. Format follows [Keep a Changelog](https://k
18
32
 
19
33
  - Renamed the package from `dsh-mydesk` to `dsh-localdesk`: the old name was published to npm by another author before this package could claim it. Routes moved to `/dsh-localdesk/*`, slot ids to `localdesk` / `localdesk-island`, and the test seam to `DSH_LOCALDESK_HOME`. Display name ("My desk" / 「我的工作台」) is unchanged.
20
34
 
35
+ ## 0.4.3 - 2026-11-24
36
+
37
+ ### Changed
38
+
39
+ - Added `repository`, `homepage`, and `bugs` metadata so the npm page links to the source.
40
+ - README now carries a real window screenshot of the desk header (`assets/hero.png`); the PNG is included in the published package.
41
+ - Island: metric labels are full words ("运行中" / "有变动") instead of abbreviations, hovering shows a small preview with the counts and the most relevant row, and decorative animations (sheen, breathing dot, gradients) are gone. The desk keeps the native DSH surface with a hover accent on rows.
42
+
43
+ ## 0.4.4 - 2026-11-24
44
+
45
+ ### Added
46
+
47
+ - MyFlicker source: reads `~/.myflicker/sessions/*` (workspace name, last activity, Claude transcript timestamps) and shows one row per session. A session is `running` while MyFlicker is open and the session changed in the last three minutes. Clicking a row opens MyFlicker through the existing allowlist.
48
+ - The source is optional: machines without MyFlicker simply see no section instead of an error.
49
+
50
+ ## 0.4.5 - 2026-11-30
51
+
52
+ ### Added
53
+
54
+ - Auto-discovery source: scans `~/Library/Application Support`, keeps up to six directories whose files changed in the last six hours, and lists the app name and newest activity. Known apps (discovery excludes browsers, editors, and the sources above) are skipped; only directory names and mtimes are read, never file contents. Discovered rows have no jump.
55
+
56
+ ## 0.5.0 - 2026-11-30
57
+
58
+ ### Added
59
+
60
+ - Desktop island helper for macOS (`helper/`): a borderless always-on-top pill that shows the same counts outside the DSH window, expands to the top five rows, opens the app for app rows and DSH otherwise. It hides itself when DSH is frontmost (the in-page island takes over) or when the snapshot stops arriving, and installs as a LaunchAgent with `helper/install.sh`.
61
+ - The Host writes `~/Library/Application Support/dsh-localdesk/status.json` every three seconds (atomic rename, mode 0600, only its own cache directory) for the helper to read.
62
+ - The published package now includes the helper sources and scripts.
63
+ - Right-click menu: hide for an hour, show now, or quit until the next login; crashes restart automatically (`KeepAlive` on unsuccessful exit).
64
+
65
+ ## 0.6.0 - 2026-11-30
66
+
67
+ ### Added
68
+
69
+ - Kim unread source: every 60 seconds the Host runs `mycli kim sessions` (read-only, session metadata only: title, unread count, last activity) and lists conversations with unread messages as `waiting`. Failures degrade silently; no message content, history, or raw database access. Source disabled unless mycli exists.
70
+ - Per-source switches in the panel (`Sources`): enable or disable codex, kim, myflicker, wechat, files, discovered and process; DSH stays on. Choices persist in `~/Library/Application Support/dsh-localdesk/settings.json` (0600) and apply without restarting the plugin.
71
+
72
+ ### Fixed
73
+
74
+ - The desktop snapshot now sorts running items first instead of emitting the first 24 rows in section order.
75
+
76
+ ## 0.7.0 - 2026-11-30
77
+
78
+ ### Added
79
+
80
+ - Manual review marks: completed or failed items carry `needsReview` until you press ✓ on the row (or "Mark all reviewed"). Marks live in `~/Library/Application Support/dsh-localdesk/reviewed.json` (0600, 30-day TTL); the desk shows a "To review" stat and filter, and the desktop island leads with the pending-review count.
81
+
82
+ ### Fixed
83
+
84
+ - Discovered apps no longer include `@deepseek-ai`, `dsh-localdesk`, `CrashReporter`, or reverse-DNS directories (`com.*`, `org.*`, `cn.*`, `net.*`, `io.*`).
85
+ - The "changed" stat now counts rows whose status is changed, so the number matches the visible rows.
86
+ - Sessions without a live id no longer produce a `dsh:session:undefined` row.
87
+
88
+ ## 0.7.1 - 2026-11-30
89
+
90
+ ### Fixed
91
+
92
+ - Stop watching Kim's data directory from the app-data source: reading Kim through `mycli` updates its DB/WAL mtimes, which made our own polling look like a Kim change. Kim now surfaces only through its unread source.
93
+
94
+ ## 0.8.0 - 2026-11-30
95
+
96
+ ### Changed
97
+
98
+ - Titles are identifiable: DSH sessions use the active goal's objective (or `label · HH:mm`), Codex sessions use the first user message (or `label · time`), MyFlicker sessions carry a time suffix. The duplicated `vibecoding` / `jason` rows are gone.
99
+ - Review queue starts clean: only completed/failed items from the last 72 hours and after the first install count; historical completions are treated as already seen. `reviewed.json` now carries `baselineAt`.
100
+ - Stats are split: **To review / Executing / Waiting on me / Apps open**. Executing excludes the process source, so open apps no longer inflate the number. The desktop island and panel follow the same four counts.
101
+
102
+ ## 0.8.1 - 2026-11-30
103
+
104
+ ### Changed
105
+
106
+ - Only one island is visible: the in-page island hides when the DSH window loses focus, and the desktop helper hides when DSH is frontmost. Switching apps hands the island over instead of showing both.
107
+ - The desktop helper expands into the same compact card as the in-page island (380 px, single column, five rows, "Open desk" footer) instead of a full-width panel; dragging is removed so it stays top-center.
108
+
109
+ ## 0.8.2 - 2026-12-01
110
+
111
+ ### Changed
112
+
113
+ - The desktop helper card now follows the in-page island's exact card spec: 380 px, 12 px radius, 33 px header, 30 px rows with separators, 12.5 px titles, kind labels, and a 40 px footer with the same button. Esc also collapses it (the helper becomes key while open).
114
+
115
+ ## 0.8.3 - 2026-12-01
116
+
117
+ ### Changed
118
+
119
+ - The desktop card uses the in-page card's exact metrics: 380 px, 12 px radius, 38 px header, 34 px rows, 44 px footer, 13 px titles, 11 px kind labels. It now paints with an explicit near-white fill and light hairlines instead of the system separator color, so it no longer looks like a darker, boxier control.
120
+ - The helper stays on the primary display (`NSScreen.screens.first`) instead of following whichever screen is main.
121
+
122
+ ## 0.9.0 - 2026-12-01
123
+
124
+ ### Changed
125
+
126
+ - The external island is now a pill only. Clicking it writes an open-desk request and activates DSH; the in-page island picks the request up on its next poll and switches the desk panel to `localdesk`. There is no second card outside the window, so the two islands can never present two different designs.
127
+ - The collapsed in-page island polls every four seconds so the hand-off is quick.
128
+
129
+ ## 0.10.0 - 2026-12-01
130
+
131
+ ### Added
132
+
133
+ - Antigravity source: reads `~/.gemini/antigravity/conversation_summaries.db` read-only (sqlite3, fixed query) and lists the 24 most recent conversations with title, workspace, step count and status. `CASCADE_RUN_STATUS_RUNNING` maps to running; idle conversations stay idle and do not enter the review queue. Clicking a row opens Antigravity.
134
+ - Antigravity is excluded from the shallow app-discovery source so it no longer appears twice.
135
+
136
+ ## 0.11.0 - 2026-12-01
137
+
138
+ ### Added
139
+
140
+ - Claude Code source: reads `~/.claude/projects/**/*.jsonl` heads for the first user message, cwd and session id; recent writes (<3 min) are running, otherwise idle; no jump.
141
+ - Harness coverage in the Sources panel: DSH, Codex, Antigravity, Claude Code, MyFlicker and Cursor are listed with detected / adapted / enabled state, so "all harnesses" is visible instead of implied.
142
+
143
+ ### Removed
144
+
145
+ - The generic Application Support discovery source. It could only prove that an app wrote a file, not that it had a task, and it duplicated dedicated sources. Chat sources (Kim, WeChat) stay enabled and opt-out through the existing switches.
146
+
147
+ ## 0.11.1 - 2026-12-01
148
+
149
+ ### Fixed
150
+
151
+ - Done/failed items without a completion timestamp no longer stay in the review queue forever (team tasks and ended schedules hit this). The review window requires a timestamp.
152
+
153
+ ## 0.11.2 - 2026-12-01
154
+
155
+ ### Changed
156
+
157
+ - Review affordance is explicit: rows that need review carry a "To review" badge, a brand left edge and tint, and a labelled "✓ Seen" pill instead of a small unlabelled circle. The bulk "Mark all reviewed" button is highlighted too.
158
+
159
+ ## 0.11.3 - 2026-12-01
160
+
161
+ ### Changed
162
+
163
+ - Background job titles are extracted from the command instead of copying the whole shell string: a leading `cd … &&` is stripped, and a `for`/`while` loop is reduced to its last tool invocation (for example `npm publish`).
164
+
165
+ ## 0.12.0 - 2026-12-01
166
+
167
+ ### Changed
168
+
169
+ - The desk is grouped by the task each row belongs to instead of by source. DSH jobs, goals, team tasks and schedules sit under their Session (header shows the Session's goal/objective); Codex, Antigravity, Claude Code, MyFlicker, Kim and WeChat conversations are their own task; files and processes fall into a "This machine" group. Each row carries a kind chip, and the task header is clickable when it has a target.
170
+
171
+ ## 0.12.1 - 2026-12-01
172
+
173
+ ### Changed
174
+
175
+ - The island card follows the same task grouping: it shows up to five owning tasks with an item count instead of raw job/command rows, and clicking a group opens its session or conversation.
176
+
177
+ ## 0.12.2 - 2026-12-02
178
+
179
+ ### Fixed
180
+
181
+ - Antigravity conversations without a title are no longer listed as `Antigravity <id>` rows. Only titled conversations and a running untitled conversation are shown; 83 of the 86 local summaries had empty titles, which flooded the desk with opaque rows.
182
+
183
+ ## 0.12.3 - 2026-12-02
184
+
185
+ ### Fixed
186
+
187
+ - Antigravity's live summaries DB is WAL-locked, so direct sqlite3 reads started failing. The Host now copies the DB (mode 0600), queries the copy, and deletes it immediately.
188
+
189
+ ## 0.13.0 - 2026-12-02
190
+
191
+ ### Changed
192
+
193
+ - MyFlicker sessions now use the first real user message as their title (system reminders stripped) and group under their workspace. Only sessions from the last seven days are considered, and each workspace keeps at most eight idle sessions.
194
+ - Codex and Claude Code sessions group under their project (`cwd`) instead of appearing as separate top-level tasks.
195
+
196
+ ## 0.13.1 - 2026-12-02
197
+
198
+ ### Fixed
199
+
200
+ - Antigravity rows can open the app again: `Antigravity` is now in the fixed app allowlist (it is not process-scanned).
201
+ - `changed` rows show "有变动" instead of "未知"; the status label had no `changed` branch.
202
+ - Group headers and row kind chips no longer fall back to "条目": `workspace`, `project`, `machine` and `kim` have labels, and MyFlicker rows say "MyFlicker" instead of "会话".
203
+ - The desktop snapshot uses `item.id`; it no longer writes `source:kind:undefined` ids.
204
+
21
205
  ## Unreleased
22
206
 
23
207
  ### Fixed
package/README.md CHANGED
@@ -1,60 +1,95 @@
1
1
  # dsh-localdesk
2
2
 
3
- A read-only observatory for your machine: what is running right now, and what just changed.
3
+ A local task radar for DSH and other coding harnesses: what is executing, what is waiting on you, and what finished but you have not reviewed yet.
4
4
 
5
- ## What it shows (0.4.1 / P4)
5
+ ![My desk: header, summary and the island](assets/hero.png)
6
+
7
+ The desk is grouped by **task**, not by source: a DSH Session is the group and uses its own short title, and its jobs, goals, team tasks and schedules are rows under it. MyFlicker sessions group by workspace, Codex and Claude Code by project; files and processes fall into "This machine".
8
+
9
+ ## What it shows
6
10
 
7
11
  | Section | Source | Per row |
8
12
  | --- | --- | --- |
9
- | Sessions | live DSH Agents + each Session's own log | directory, model, turn, last activity; click to open |
10
- | Background jobs | `jobs` registry events (all owners) | command, owner Session, progress, output size |
13
+ | DSH sessions | live Agents + each Session's own log | DSH's own short title, else goal/objective, else `cwd · time`; model, turn, last activity; click to open |
14
+ | Background jobs | `jobs` registry events (all owners) | action extracted from the command (for a shell loop, the last tool invocation), owner Session, progress, output size |
11
15
  | Scheduled tasks | `schedule.catalog()` | title, timing, next run, target Session |
12
16
  | Goals | `goals.get(agent)` | objective, phase, rounds |
13
17
  | Team tasks | `agentTeams.listTasks(agent)` | subject, status, owner, blocked |
14
- | Codex sessions | `~/.codex/sessions/**/rollout-*.jsonl` (head + tail only) | project, event count, CLI version, provider, running/idle/done |
18
+ | Codex | `~/.codex/sessions/**/rollout-*.jsonl` (head + tail) | first user message as title, project, events, CLI version, provider |
19
+ | Antigravity | `~/.gemini/antigravity/conversation_summaries.db` (read from a temporary immutable copy) | titled conversations only; untitled idle runs hidden, steps, `RUNNING`/`IDLE` |
20
+ | Claude Code | `~/.claude/projects/**/*.jsonl` (head) | first user message as title, project, recent-write activity |
21
+ | MyFlicker | `~/.myflicker/sessions` | first user message per session, grouped by workspace; last write; click to open the app |
22
+ | Kim | `mycli kim sessions` (metadata only) | unread conversations, unread count, last activity |
15
23
  | WeChat channel | DSH's own `~/.dsh/channel-wechat/peer-sessions.json` | peer, linked Session; click to open |
16
- | App data | mtimes under `.claude`, `.cursor`, Kim's data dirs | which app data changed, when, which child moved |
24
+ | App data | mtimes under `.cursor` (and `.claude` only when the Claude adapter is absent) | which app data changed, when, which child moved |
17
25
  | Local apps | allowlisted `pgrep` | app name, matching processes; click to bring it forward |
18
26
 
27
+ The generic Application Support discovery source was removed in 0.11.0: it could only prove that an app wrote a file, not that it had a task. Harness coverage is explicit instead — the Sources panel lists DSH, Codex, Antigravity, Claude Code, MyFlicker and Cursor with **detected / adapted / enabled** state.
28
+
29
+ ## The three numbers
30
+
31
+ - **To review** — completed or failed, inside the last 72 hours and after the first install, until you tick ✓ or press **Mark all reviewed**. Stored in the plugin's own `reviewed.json` (0600, 30-day TTL).
32
+ - **Executing** — real execution state from DSH sessions/jobs/goals/team tasks, the Codex `task_started` marker, Antigravity's run status, Claude Code's recent writes. Process rows do not count here.
33
+ - **Waiting on me** — Kim unread conversations, blocked goals, waiting team tasks. WeChat has no unread source, so it stays at the channel level.
34
+
35
+ ## Desktop island (macOS)
36
+
37
+ The in-window island hides when the DSH window loses focus; the external helper hides when DSH is frontmost, so only one is visible at a time.
38
+
39
+ The helper is a counts-only pill whose width follows its metrics; it turns amber when anything needs review. Clicking it writes an open-desk request and activates DSH; the in-page island refreshes immediately on window focus and switches the desk panel to `localdesk`.
40
+
41
+ ```bash
42
+ bash helper/install.sh # builds the Swift helper and loads a LaunchAgent
43
+ bash helper/uninstall.sh # removes the LaunchAgent and the binary
44
+ ```
45
+
46
+ It reads `~/Library/Application Support/dsh-localdesk/status.json` (written by the Host every three seconds, mode 0600) and stops showing when the snapshot goes stale. It is a locally built, unsigned binary; removing it is a one-liner.
47
+
48
+ ## Source switches
49
+
50
+ The panel's **Sources** button turns any source except DSH on or off. Choices persist in `~/Library/Application Support/dsh-localdesk/settings.json` (0600) and apply without restarting the plugin. Chat sources (Kim, WeChat) are enabled by default and can be switched off; disabling a source removes its rows, its counts and its snapshot entries.
51
+
19
52
  ## Where it lives
20
53
 
21
54
  - Sidebar entry **My desk** (「我的工作台」) and its main panel.
22
- - A frame-wide island at the top of the window: collapsed it shows run / wait / changed counts and refreshes every 10s; click it for the top five items and an **Open desk** button. It hides itself when there is nothing to show, refreshes every 2.5s while open, and closes on Esc or an outside click.
23
- - One read-only route `GET /dsh-localdesk/state` behind the same connection trust as the app.
24
- - One action route `POST /dsh-localdesk/open`, used only when you click a row whose target is a local app. It accepts an allowlisted app name or an `http(s)` URL, never a shell string.
55
+ - A frame-wide island at the top of the window: counts, top five items, **Open desk**. It hides when there is nothing to show, refreshes every 2.5s while open, and closes on Esc or an outside click.
56
+ - Routes behind the app's connection trust:
57
+ - `GET /dsh-localdesk/state`
58
+ - `POST /dsh-localdesk/open` (allowlisted app or `http(s)` URL, never a shell string)
59
+ - `POST /dsh-localdesk/settings` (`source`, `enabled`)
60
+ - `POST /dsh-localdesk/review` (`id`, or `{ all: true }`)
25
61
 
26
- ## Filtering
62
+ ## Boundaries
27
63
 
28
- The desk has a search box (title, path, owner, meta, tags) and status chips (All / Running / Waiting / Changed). Filtering is client-side: the summary above stays global, section counts show what survived the filter, and an empty result says so instead of hiding the page.
64
+ - **Metadata only**: titles, states, timestamps, counts. Message bodies are not read.
65
+ - **Writes stay in the plugin's own cache**: `status.json`, `settings.json`, `reviewed.json`, `open-request`. No Session event is appended and no other app's state changes.
66
+ - **Kim** is read through `mycli kim sessions` only (titles, unread counts, last activity); no `history`/`query`, no SQLCipher access.
67
+ - **Antigravity** is read through a fixed read-only `sqlite3` query against `conversation_summaries.db`.
68
+ - Plugin subprocesses are not sandboxed by DSH, so every command is fixed-argv and allowlisted.
69
+ - A failing source is isolated: its card shows an error, the rest of the desk keeps rendering.
29
70
 
30
- ## Boundaries
71
+ ## Filtering
31
72
 
32
- - **Read-only**: no Session event is appended, no task state changes, nothing leaves the machine.
33
- - **This process, this machine**: DSH items come from the current process; Codex, app-data and app rows come from the machine. Durable Sessions from other DSH processes are not listed yet (P2 scope kept this out).
34
- - **No content reads**: only metadata — titles, states, timestamps, counts.
35
- - **Kim is not read**: its local databases are SQLCipher-encrypted; only the separate `mycli` tool can open them. The Kim row you see comes from the generic app-data watcher, not from decryption.
36
- - Plugin subprocesses are not sandboxed by DSH, so every command this plugin runs is fixed-argv and allowlisted (see `docs/DECISIONS.md` D8).
73
+ The desk has a search box (title, path, owner, meta, tags) and status chips (All / Running / Waiting / Changed / To review). Filtering is client-side: the summary above stays global, section counts show what survived the filter, and an empty result says so instead of hiding the page.
37
74
 
38
75
  ## Layout
39
76
 
40
- - Sources live in `index.js` behind one `Item` contract (see `docs/CONTRACTS.md`); the client renders that contract and nothing else.
41
- - `test/probe.mjs` runs both halves against fixtures and a fake Cordis context: `node test/probe.mjs` (64 checks).
42
- - The island is client-only; it reads the same `/state` route with a lower cadence while collapsed.
43
- - No screenshots are bundled: this environment has no browser control to capture the real page. The layout follows the shipped DSH management pages and uses only `--dsw-alias-*` theme tokens.
77
+ - Sources live in `index.js` behind one `Item` contract; the client renders that contract and nothing else.
78
+ - `test/probe.mjs` runs both halves against fixtures and a fake Cordis context: `node test/probe.mjs` (108 checks).
79
+ - The Host reports its version through `/state`; if the page is newer than the Host half, the desk says so and asks for a restart instead of silently showing an older source set.
44
80
 
45
81
  ## Compatibility
46
82
 
47
83
  - Requires Node `^22.19.0 || >=24.0.0` (the DSH app runtime).
48
84
  - Hard dependencies: `webServer`, `connection`, `agents`. Without them the plugin does not activate.
49
- - Optional services: `jobs`, `schedule`, `goals`, `agentTeams`, `subprocess`. A profile that lacks one degrades per source — that source reports `unavailable`/`error`, every other source keeps working (the probe covers exactly this).
50
- - A source that fails at scan time is isolated: its card shows an error, the rest of the desk still renders.
51
- - The Host reports its version through `/state`; if the page is newer than the Host half (a client update without a restart), the desk says so and asks for a restart instead of silently showing an older source set.
85
+ - Optional services: `jobs`, `schedule`, `goals`, `agentTeams`, `subprocess`. A profile that lacks one degrades per source; every other source keeps working.
86
+ - Optional tools: `mycli` for Kim (source absent without it), `sqlite3` for Antigravity, the Swift helper for the desktop pill.
52
87
 
53
88
  ## Install
54
89
 
55
- ```bash
56
- # Plugins > Add plugin, pick this directory — or install the local package.
57
- ```
90
+ The npm package `dsh-localdesk` exists, but `latest` is still an older release while 0.11.0 is validated locally. Until the next publish, install this directory in DSH (Plugins > Add plugin) or use the GitHub checkout.
91
+
92
+ Ignore the `0.0.0-stage` placeholder version that npm creates for a brand-new package name.
58
93
 
59
94
  ## License
60
95
 
Binary file