forkoff 1.0.18 → 1.0.19

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.
Files changed (3) hide show
  1. package/LICENSE +11 -7
  2. package/README.md +77 -118
  3. package/package.json +2 -2
package/LICENSE CHANGED
@@ -1,12 +1,16 @@
1
- Copyright (c) 2026 ForkOff. All rights reserved.
1
+ MIT License
2
2
 
3
- This software and associated documentation files (the "Software") are the
4
- proprietary property of ForkOff. The Software is provided for viewing and
5
- reference purposes only.
3
+ Copyright (c) 2026 ForkOff
6
4
 
7
- No part of the Software may be copied, modified, merged, published,
8
- distributed, sublicensed, sold, or otherwise used without the prior written
9
- permission of ForkOff.
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
10
14
 
11
15
  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
12
16
  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
package/README.md CHANGED
@@ -5,37 +5,31 @@
5
5
  <h1 align="center">ForkOff CLI</h1>
6
6
 
7
7
  <p align="center">
8
- <strong>Bridge your AI coding tools to your mobile device</strong>
8
+ <strong>Control your AI coding sessions from your phone</strong>
9
9
  </p>
10
10
 
11
- > ## 🚀 **OPEN BETA**
12
- >
13
- > ForkOff is now in **open beta**! Download the mobile app and get started:
14
- >
15
- > 📱 **[Join the TestFlight Beta](https://testflight.apple.com/join/dhh5FrN7)**
16
-
17
- ---
11
+ <p align="center">
12
+ <a href="https://www.npmjs.com/package/forkoff"><img src="https://img.shields.io/npm/v/forkoff.svg" alt="npm version"></a>
13
+ <a href="https://github.com/Forkoff-app/forkoff-cli/blob/main/LICENSE"><img src="https://img.shields.io/npm/l/forkoff.svg" alt="MIT License"></a>
14
+ <a href="https://www.npmjs.com/package/forkoff"><img src="https://img.shields.io/npm/dm/forkoff.svg" alt="npm downloads"></a>
15
+ </p>
18
16
 
19
17
  <p align="center">
20
- <a href="https://forkoff.app">Website</a>
21
- <a href="#installation">Installation</a>
22
- <a href="#quick-start">Quick Start</a>
23
- <a href="#commands">Commands</a>
24
- <a href="#programmatic-usage">API</a>
25
- <a href="#configuration">Configuration</a>
18
+ <a href="https://forkoff.app">Website</a> &bull;
19
+ <a href="#installation">Installation</a> &bull;
20
+ <a href="#quick-start">Quick Start</a> &bull;
21
+ <a href="#commands">Commands</a> &bull;
22
+ <a href="#programmatic-usage">API</a> &bull;
23
+ <a href="#security">Security</a>
26
24
  </p>
27
25
 
28
26
  ---
29
27
 
30
- ## Overview
28
+ ForkOff CLI connects [Claude Code](https://claude.ai/code) on your laptop to the ForkOff mobile app, giving you real-time monitoring, interactive approvals, and usage analytics from anywhere.
31
29
 
32
- ForkOff CLI connects your development machine to the ForkOff mobile app, enabling you to:
33
-
34
- - **Control AI coding sessions** from your phone
35
- - **Approve code changes** on the go
36
- - **Send prompts** to Claude, Cursor, and other AI tools
37
- - **Monitor progress** in real-time
38
- - **Get notifications** for permission requests
30
+ > **Open Source** &mdash; ForkOff CLI is now MIT licensed. Contributions welcome!
31
+ >
32
+ > **Open Beta** &mdash; [Join the iOS TestFlight](https://testflight.apple.com/join/dhh5FrN7)
39
33
 
40
34
  ## Installation
41
35
 
@@ -45,24 +39,35 @@ npm install -g forkoff
45
39
 
46
40
  ## Quick Start
47
41
 
48
- ### 1. Pair with Mobile App
42
+ ### 1. Pair with your phone
49
43
 
50
44
  ```bash
51
45
  forkoff pair
52
46
  ```
53
47
 
54
- Scan the QR code with your ForkOff mobile app to link your device.
48
+ Scan the QR code with the ForkOff mobile app to link your device.
55
49
 
56
- ### 2. Stay Connected
50
+ ### 2. Stay connected
57
51
 
58
52
  ```bash
59
53
  forkoff connect
60
54
  ```
61
55
 
62
- Keep this running to receive commands from your mobile app.
56
+ Keep this running to stream sessions to your phone in real-time.
63
57
 
64
58
  ---
65
59
 
60
+ ## Features
61
+
62
+ - **Real-time session monitoring** &mdash; See Claude Code output on your phone as it happens
63
+ - **Interactive approvals** &mdash; Approve or deny tool use (file edits, bash commands) from mobile
64
+ - **Configurable permission rules** &mdash; Auto-approve safe tools, require approval for destructive ones
65
+ - **End-to-end encryption** &mdash; All session data encrypted between CLI and mobile
66
+ - **Usage analytics** &mdash; Track token usage, session counts, and streaks across devices
67
+ - **Multi-device support** &mdash; Connect multiple CLI instances, analytics aggregate automatically
68
+ - **Auto-start** &mdash; Optionally launch on login so your phone is always connected
69
+ - **Direct P2P connection** &mdash; Embedded relay server, no cloud dependency for session data
70
+
66
71
  ## Commands
67
72
 
68
73
  | Command | Description |
@@ -70,31 +75,18 @@ Keep this running to receive commands from your mobile app.
70
75
  | `forkoff pair` | Generate QR code to pair with mobile app |
71
76
  | `forkoff connect` | Connect and listen for commands |
72
77
  | `forkoff status` | Check connection status |
73
- | `forkoff disconnect` | Disconnect from server |
78
+ | `forkoff disconnect` | Disconnect and unpair device |
74
79
  | `forkoff config` | View/modify configuration |
75
80
  | `forkoff startup` | Manage automatic startup on login |
76
- | `forkoff startup --enable` | Enable automatic startup |
77
- | `forkoff startup --disable` | Disable automatic startup |
78
- | `forkoff startup --status` | Show startup registration status |
79
- | `forkoff help` | Show available commands and usage |
81
+ | `forkoff tools` | Detect AI coding tools on your machine |
82
+ | `forkoff logs` | List debug log files for troubleshooting |
80
83
 
81
- ### Configuration Options
84
+ ### Configuration
82
85
 
83
86
  ```bash
84
- # Show current configuration
85
- forkoff config --show
86
-
87
- # Set custom API URL
88
- forkoff config --api https://your-server.com/api
89
-
90
- # Set custom WebSocket URL
91
- forkoff config --ws wss://your-server.com
92
-
93
- # Set device name
94
- forkoff config --name "My MacBook Pro"
95
-
96
- # Reset all configuration
97
- forkoff config --reset
87
+ forkoff config --show # Show current config
88
+ forkoff config --name "My MBP" # Set device name
89
+ forkoff config --reset # Reset to defaults
98
90
  ```
99
91
 
100
92
  ### Global Options
@@ -102,93 +94,64 @@ forkoff config --reset
102
94
  | Option | Description |
103
95
  |--------|-------------|
104
96
  | `-q, --quiet` | Suppress all output (for background operation) |
105
-
106
- ### Background Operation
107
-
108
- Run ForkOff silently in the background with no console output:
109
-
110
- ```bash
111
- forkoff connect --quiet
112
- ```
113
-
114
- This is used by the automatic startup feature and is useful for running ForkOff as a background service.
97
+ | `--debug` | Enable debug logging to file (`~/.forkoff-cli/logs/`) |
115
98
 
116
99
  ### Automatic Startup
117
100
 
118
- ForkOff automatically starts on login so your device stays connected without manual intervention. Startup is **enabled by default** when you run `forkoff pair` or `forkoff connect`, it registers itself to launch `forkoff connect --quiet` on login.
101
+ Startup is enabled by default &mdash; `forkoff pair` and `forkoff connect` register the CLI to launch on login.
119
102
 
120
- - **Windows**: Adds a `ForkOffCLI` entry to the `HKCU\...\Run` registry key (no admin required)
121
- - **macOS**: Installs a launchd agent (`~/Library/LaunchAgents/app.forkoff.cli.plist`) with the explicit node binary path for nvm/fnm compatibility
122
-
123
- To disable automatic startup:
103
+ - **Windows**: Registry key (`HKCU\...\Run`)
104
+ - **macOS**: launchd agent (`~/Library/LaunchAgents/app.forkoff.cli.plist`)
124
105
 
125
106
  ```bash
126
- forkoff startup --disable
107
+ forkoff startup --disable # Disable auto-start
108
+ forkoff startup --enable # Re-enable
109
+ forkoff startup --status # Check registration
127
110
  ```
128
111
 
129
- Once disabled, `pair` and `connect` will not re-register startup. To re-enable:
112
+ ---
113
+
114
+ ## Security
130
115
 
131
- ```bash
132
- forkoff startup --enable
133
- ```
116
+ All communication between the CLI and mobile app is end-to-end encrypted. The relay server never sees plaintext session data.
117
+
118
+ | Layer | Implementation |
119
+ |-------|---------------|
120
+ | **Key exchange** | X25519 ECDH with Ed25519 identity signatures |
121
+ | **Encryption** | XSalsa20-Poly1305 authenticated encryption (NaCl) |
122
+ | **Identity** | TOFU (Trust On First Use) with key pinning |
123
+ | **Replay protection** | Per-peer monotonic message counters |
124
+ | **Key storage** | OS keychain (macOS Keychain, Windows Credential Manager, Linux libsecret) |
125
+ | **Enforcement** | Sensitive events (session content, approvals, files) never sent in plaintext |
134
126
 
135
- Running `forkoff disconnect` also removes the startup registration.
127
+ No additional setup required &mdash; E2EE is enabled automatically when you pair.
136
128
 
137
129
  ---
138
130
 
139
131
  ## Programmatic Usage
140
132
 
141
- Integrate ForkOff into your AI coding tools:
133
+ Integrate ForkOff into your own AI coding tools:
142
134
 
143
135
  ```typescript
144
136
  import { createIntegration } from 'forkoff';
145
137
 
146
138
  const forkoff = createIntegration();
147
-
148
- // Connect to ForkOff server
149
139
  await forkoff.connect();
150
140
 
151
- // Handle incoming messages from mobile app
152
- forkoff.onMessageReceived((sessionId, content, requestedBy) => {
153
- console.log(`Message from ${requestedBy}: ${content}`);
154
-
155
- // Send a response
156
- forkoff.sendMessage(sessionId, 'Processing your request...');
157
- });
158
-
159
- // Stream responses in real-time
160
- const stream = forkoff.startStreaming(sessionId);
161
- stream.write('Here is ');
162
- stream.write('a streaming ');
163
- stream.write('response.');
164
- stream.end();
165
-
166
141
  // Request approval for code changes
167
142
  const approval = await forkoff.requestApproval(
168
- sessionId,
169
- messageId,
170
- 'CODE_CHANGE',
171
- 'Add authentication middleware',
143
+ sessionId, messageId, 'CODE_CHANGE',
144
+ 'Add auth middleware',
172
145
  { filePath: 'src/middleware/auth.ts', diff: '...' }
173
146
  );
174
147
 
175
- if (approval.status === 'approved') {
176
- // Apply the changes
177
- }
178
-
179
- // Send terminal output
180
- forkoff.sendTerminalOutput(sessionId, '> npm install\n Done', 'stdout');
181
- forkoff.sendTerminalExit(sessionId, 0);
182
-
183
- // Update device status
184
- forkoff.setStatus('busy');
148
+ // Stream terminal output
149
+ forkoff.sendTerminalOutput(sessionId, '> npm install\nDone', 'stdout');
185
150
  ```
186
151
 
187
152
  ---
188
153
 
189
- ## Configuration
190
-
191
- Configuration files are stored at:
154
+ ## Configuration Files
192
155
 
193
156
  | Platform | Location |
194
157
  |----------|----------|
@@ -196,26 +159,22 @@ Configuration files are stored at:
196
159
  | **macOS** | `~/Library/Preferences/forkoff-cli/config.json` |
197
160
  | **Linux** | `~/.config/forkoff-cli/config.json` |
198
161
 
199
- ---
200
-
201
- ## Security
202
-
203
- Your data stays yours. All communication between the ForkOff CLI and your mobile device is protected with **end-to-end encryption (E2EE)**:
204
-
205
- - Messages, code, and commands are encrypted on-device before leaving your machine
206
- - The ForkOff server never sees your plaintext data — it only relays encrypted payloads
207
- - Each device pair establishes a unique encrypted channel using ephemeral key exchange
208
- - Session keys are derived per-connection, so even if one session is compromised, others remain secure
162
+ ## Development
209
163
 
210
- No additional setup required — E2EE is enabled automatically when you pair your device.
164
+ ```bash
165
+ git clone https://github.com/Forkoff-app/forkoff-cli.git
166
+ cd forkoff-cli
167
+ npm install
168
+ npm run dev # Run with ts-node
169
+ npm run build # Compile TypeScript
170
+ npm test # Run tests
171
+ ```
211
172
 
212
173
  ## Requirements
213
174
 
214
175
  - Node.js 18+
215
- - ForkOff mobile app
176
+ - [ForkOff mobile app](https://testflight.apple.com/join/dhh5FrN7) (iOS)
216
177
 
217
- ---
178
+ ## License
218
179
 
219
- <p align="center">
220
- Made with ❤️ by the ForkOff team
221
- </p>
180
+ [MIT](LICENSE)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "forkoff",
3
- "version": "1.0.18",
3
+ "version": "1.0.19",
4
4
  "description": "CLI tool to connect your AI coding tools to mobile | Open Beta - Download the app: https://testflight.apple.com/join/dhh5FrN7",
5
5
  "main": "dist/integration.js",
6
6
  "types": "dist/integration.d.ts",
@@ -48,7 +48,7 @@
48
48
  "email": "support@forkoff.app",
49
49
  "url": "https://forkoff.app"
50
50
  },
51
- "license": "Proprietary",
51
+ "license": "MIT",
52
52
  "dependencies": {
53
53
  "chalk": "^4.1.2",
54
54
  "chokidar": "^3.6.0",