taskwindow 0.1.8 → 0.1.9
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 +10 -14
- package/package.json +1 -1
- package/src/index.js +9 -4
package/README.md
CHANGED
|
@@ -12,34 +12,30 @@ MCP over HTTP.
|
|
|
12
12
|
|
|
13
13
|
## Setup (5 minutes)
|
|
14
14
|
|
|
15
|
-
### 1.
|
|
15
|
+
### 1. Install and start the daemon
|
|
16
16
|
|
|
17
17
|
Requires Node 18+.
|
|
18
18
|
|
|
19
19
|
```bash
|
|
20
|
-
|
|
20
|
+
npm install -g taskwindow
|
|
21
|
+
taskwindow install
|
|
21
22
|
```
|
|
22
23
|
|
|
23
|
-
|
|
24
|
+
That installs a login service (the daemon starts now and after every laptop
|
|
25
|
+
restart — no terminal needed) and prints:
|
|
24
26
|
|
|
25
27
|
```
|
|
26
|
-
[taskwindow]
|
|
28
|
+
[taskwindow] login service installed (~/Library/LaunchAgents/com.clawnify.taskwindow.plist)
|
|
27
29
|
[taskwindow] pairing code: A6LU5X — enter it in the TaskWindow extension options
|
|
28
|
-
[taskwindow] claude code: claude mcp add taskwindow --transport http http://127.0.0.1:9377/mcp --header "Authorization: Bearer …"
|
|
29
30
|
```
|
|
30
31
|
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
```bash
|
|
35
|
-
npm install -g taskwindow
|
|
36
|
-
taskwindow install
|
|
37
|
-
```
|
|
38
|
-
|
|
39
|
-
Or just keep `npx taskwindow` running in a terminal — both work.
|
|
32
|
+
Keep the pairing code for step 3. (Prefer running it by hand? `npx taskwindow`
|
|
33
|
+
in a terminal works too — it just won't survive a restart.)
|
|
40
34
|
|
|
41
35
|
### 2. Install the Chrome extension
|
|
42
36
|
|
|
37
|
+
You already have the CLI — add the extension:
|
|
38
|
+
|
|
43
39
|
```bash
|
|
44
40
|
taskwindow install --extension
|
|
45
41
|
```
|
package/package.json
CHANGED
package/src/index.js
CHANGED
|
@@ -12,6 +12,15 @@ const { version: VERSION } = createRequire(import.meta.url)("../package.json");
|
|
|
12
12
|
import { registerClaude, registerCursor, registerOpenCode, unregisterAgents } from "./agents.js";
|
|
13
13
|
import { createInterface } from "node:readline";
|
|
14
14
|
|
|
15
|
+
// One-time pairing: the daemon prints a short code at startup; the extension
|
|
16
|
+
// exchanges it for the real token via POST /pair (loopback-only). This defends
|
|
17
|
+
// the pairing endpoint against other local user accounts; a same-user process
|
|
18
|
+
// could read the token file directly, so the code adds no obstacle there.
|
|
19
|
+
const PAIR_ALPHABET = "ABCDEFGHJKLMNPQRSTUVWXYZ23456789"; // no 0/O/1/I
|
|
20
|
+
const pairCode = Array.from(randomBytes(6))
|
|
21
|
+
.map((b) => PAIR_ALPHABET[b % PAIR_ALPHABET.length])
|
|
22
|
+
.join("");
|
|
23
|
+
|
|
15
24
|
// `taskwindow install` manages the login service and — only with an explicit
|
|
16
25
|
// per-agent flag — registers the MCP server in that agent.
|
|
17
26
|
const args = process.argv.slice(2);
|
|
@@ -79,10 +88,6 @@ if (verb === "uninstall") {
|
|
|
79
88
|
const config = loadConfig();
|
|
80
89
|
const bridge = new Bridge({ token: config.token });
|
|
81
90
|
|
|
82
|
-
const PAIR_ALPHABET = "ABCDEFGHJKLMNPQRSTUVWXYZ23456789"; // no 0/O/1/I
|
|
83
|
-
const pairCode = Array.from(randomBytes(6))
|
|
84
|
-
.map((b) => PAIR_ALPHABET[b % PAIR_ALPHABET.length])
|
|
85
|
-
.join("");
|
|
86
91
|
const handleMcp = createMcpRequestHandler({ bridge, version: VERSION });
|
|
87
92
|
|
|
88
93
|
// One-time pairing: the daemon prints a short code at startup; the extension
|