@masslessai/push-todo 3.2.1 → 3.3.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/.claude-plugin/plugin.json +1 -1
- package/lib/cli.js +1 -1
- package/package.json +1 -1
- package/scripts/postinstall.js +57 -104
package/lib/cli.js
CHANGED
|
@@ -15,7 +15,7 @@ import { ensureDaemonRunning, getDaemonStatus, startDaemon, stopDaemon } from '.
|
|
|
15
15
|
import { getScreenshotPath, screenshotExists, openScreenshot } from './utils/screenshots.js';
|
|
16
16
|
import { bold, red, cyan, dim, green } from './utils/colors.js';
|
|
17
17
|
|
|
18
|
-
const VERSION = '3.
|
|
18
|
+
const VERSION = '3.3.0';
|
|
19
19
|
|
|
20
20
|
const HELP_TEXT = `
|
|
21
21
|
${bold('push-todo')} - Voice tasks from Push iOS app for Claude Code
|
package/package.json
CHANGED
package/scripts/postinstall.js
CHANGED
|
@@ -144,7 +144,8 @@ function migrateFromPython() {
|
|
|
144
144
|
|
|
145
145
|
/**
|
|
146
146
|
* Set up OpenAI Codex integration.
|
|
147
|
-
* Creates ~/.codex/skills/push-todo
|
|
147
|
+
* Creates symlink ~/.codex/skills/push-todo -> npm package
|
|
148
|
+
* Updates AGENTS.md for session bootstrap
|
|
148
149
|
*
|
|
149
150
|
* @returns {boolean} True if Codex was detected and set up
|
|
150
151
|
*/
|
|
@@ -156,54 +157,7 @@ function setupCodex() {
|
|
|
156
157
|
|
|
157
158
|
console.log('[push-todo] Detected OpenAI Codex installation');
|
|
158
159
|
|
|
159
|
-
//
|
|
160
|
-
const SKILL_CONTENT = `# Push Tasks Skill
|
|
161
|
-
|
|
162
|
-
This skill retrieves and processes tasks sent from the Push iOS app.
|
|
163
|
-
|
|
164
|
-
## Activation
|
|
165
|
-
|
|
166
|
-
This skill activates when the user:
|
|
167
|
-
- Says "push-todo", "push todo", "push tasks", or "tasks from push"
|
|
168
|
-
- Runs \`$push-todo\` command
|
|
169
|
-
- Mentions "tasks from iPhone" or "mobile tasks"
|
|
170
|
-
- Asks about "pending tasks" or "voice tasks"
|
|
171
|
-
|
|
172
|
-
## Commands
|
|
173
|
-
|
|
174
|
-
Run these in the terminal:
|
|
175
|
-
|
|
176
|
-
| Command | Description |
|
|
177
|
-
|---------|-------------|
|
|
178
|
-
| \`push-todo\` | List active tasks |
|
|
179
|
-
| \`push-todo 427\` | Show task #427 |
|
|
180
|
-
| \`push-todo connect\` | Connect/fix issues |
|
|
181
|
-
| \`push-todo search "query"\` | Search tasks |
|
|
182
|
-
| \`push-todo --help\` | All options |
|
|
183
|
-
|
|
184
|
-
## Instructions
|
|
185
|
-
|
|
186
|
-
When this skill is activated:
|
|
187
|
-
|
|
188
|
-
1. **Check connection** - If user hasn't set up, run:
|
|
189
|
-
\`\`\`bash
|
|
190
|
-
push-todo connect
|
|
191
|
-
\`\`\`
|
|
192
|
-
|
|
193
|
-
2. **Fetch tasks** - List available tasks:
|
|
194
|
-
\`\`\`bash
|
|
195
|
-
push-todo
|
|
196
|
-
\`\`\`
|
|
197
|
-
|
|
198
|
-
3. **Work on specific task** - Get task details:
|
|
199
|
-
\`\`\`bash
|
|
200
|
-
push-todo 427
|
|
201
|
-
\`\`\`
|
|
202
|
-
|
|
203
|
-
4. **Present the task** to the user with a brief summary and offer to help implement it.
|
|
204
|
-
`;
|
|
205
|
-
|
|
206
|
-
// AGENTS.md bootstrap content
|
|
160
|
+
// AGENTS.md bootstrap content (Codex-specific)
|
|
207
161
|
const AGENTS_SECTION = `
|
|
208
162
|
## Push Tasks Integration
|
|
209
163
|
|
|
@@ -221,16 +175,38 @@ At the start of each session, check for pending tasks from the Push iOS app:
|
|
|
221
175
|
`;
|
|
222
176
|
|
|
223
177
|
try {
|
|
224
|
-
//
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
178
|
+
// Ensure skills directory exists
|
|
179
|
+
const skillsDir = join(CODEX_DIR, 'skills');
|
|
180
|
+
mkdirSync(skillsDir, { recursive: true });
|
|
181
|
+
|
|
182
|
+
// Create symlink (same as Claude Code approach)
|
|
183
|
+
if (existsSync(CODEX_SKILL_DIR)) {
|
|
184
|
+
const stats = lstatSync(CODEX_SKILL_DIR);
|
|
185
|
+
if (stats.isSymbolicLink()) {
|
|
186
|
+
const target = readlinkSync(CODEX_SKILL_DIR);
|
|
187
|
+
if (target === PACKAGE_ROOT) {
|
|
188
|
+
console.log('[push-todo] Codex: Symlink already configured');
|
|
189
|
+
} else {
|
|
190
|
+
unlinkSync(CODEX_SKILL_DIR);
|
|
191
|
+
symlinkSync(PACKAGE_ROOT, CODEX_SKILL_DIR);
|
|
192
|
+
console.log('[push-todo] Codex: Updated symlink');
|
|
193
|
+
}
|
|
194
|
+
} else {
|
|
195
|
+
// It's a directory (old copy) - remove and replace with symlink
|
|
196
|
+
rmSync(CODEX_SKILL_DIR, { recursive: true });
|
|
197
|
+
symlinkSync(PACKAGE_ROOT, CODEX_SKILL_DIR);
|
|
198
|
+
console.log('[push-todo] Codex: Replaced copy with symlink');
|
|
199
|
+
}
|
|
200
|
+
} else {
|
|
201
|
+
symlinkSync(PACKAGE_ROOT, CODEX_SKILL_DIR);
|
|
202
|
+
console.log('[push-todo] Codex: Created symlink');
|
|
203
|
+
}
|
|
228
204
|
|
|
229
205
|
// Update AGENTS.md for session-start bootstrap
|
|
230
206
|
if (existsSync(CODEX_AGENTS_FILE)) {
|
|
231
207
|
const content = readFileSync(CODEX_AGENTS_FILE, 'utf8');
|
|
232
208
|
if (content.includes('Push Tasks Integration')) {
|
|
233
|
-
// Update existing section
|
|
209
|
+
// Update existing section
|
|
234
210
|
const updated = content.replace(
|
|
235
211
|
/## Push Tasks Integration[\s\S]*?(?=\n## |$)/,
|
|
236
212
|
AGENTS_SECTION.trim() + '\n\n'
|
|
@@ -255,7 +231,7 @@ At the start of each session, check for pending tasks from the Push iOS app:
|
|
|
255
231
|
|
|
256
232
|
/**
|
|
257
233
|
* Set up Clawdbot integration.
|
|
258
|
-
* Creates ~/.clawdbot/skills/push-todo
|
|
234
|
+
* Creates symlink ~/.clawdbot/skills/push-todo -> npm package
|
|
259
235
|
*
|
|
260
236
|
* @returns {boolean} True if Clawdbot was detected and set up
|
|
261
237
|
*/
|
|
@@ -267,60 +243,37 @@ function setupClawdbot() {
|
|
|
267
243
|
|
|
268
244
|
console.log('[push-todo] Detected Clawdbot installation');
|
|
269
245
|
|
|
270
|
-
const SKILL_CONTENT = `# Push Tasks
|
|
271
|
-
|
|
272
|
-
Voice tasks captured on iPhone, ready to work on.
|
|
273
|
-
|
|
274
|
-
## Commands
|
|
275
|
-
|
|
276
|
-
Run these in the terminal:
|
|
277
|
-
|
|
278
|
-
| Command | Description |
|
|
279
|
-
|---------|-------------|
|
|
280
|
-
| \`push-todo\` | List active tasks |
|
|
281
|
-
| \`push-todo 427\` | Show task #427 |
|
|
282
|
-
| \`push-todo connect\` | Connect/fix issues |
|
|
283
|
-
| \`push-todo search "query"\` | Search tasks |
|
|
284
|
-
| \`push-todo --help\` | All options |
|
|
285
|
-
|
|
286
|
-
## Quick Start
|
|
287
|
-
|
|
288
|
-
If not connected yet, run:
|
|
289
|
-
\`\`\`bash
|
|
290
|
-
push-todo connect
|
|
291
|
-
\`\`\`
|
|
292
|
-
|
|
293
|
-
To see tasks:
|
|
294
|
-
\`\`\`bash
|
|
295
|
-
push-todo
|
|
296
|
-
\`\`\`
|
|
297
|
-
|
|
298
|
-
To work on a specific task:
|
|
299
|
-
\`\`\`bash
|
|
300
|
-
push-todo 427
|
|
301
|
-
\`\`\`
|
|
302
|
-
|
|
303
|
-
## Session Start
|
|
304
|
-
|
|
305
|
-
At the start of each session, check for tasks:
|
|
306
|
-
\`\`\`bash
|
|
307
|
-
push-todo --json 2>/dev/null | head -1
|
|
308
|
-
\`\`\`
|
|
309
|
-
If tasks exist, inform the user.
|
|
310
|
-
`;
|
|
311
|
-
|
|
312
246
|
try {
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
247
|
+
// Ensure skills directory exists
|
|
248
|
+
const skillsDir = join(CLAWDBOT_DIR, 'skills');
|
|
249
|
+
mkdirSync(skillsDir, { recursive: true });
|
|
250
|
+
|
|
251
|
+
// Create symlink (same as Claude Code approach)
|
|
252
|
+
if (existsSync(CLAWDBOT_SKILL_DIR)) {
|
|
253
|
+
const stats = lstatSync(CLAWDBOT_SKILL_DIR);
|
|
254
|
+
if (stats.isSymbolicLink()) {
|
|
255
|
+
const target = readlinkSync(CLAWDBOT_SKILL_DIR);
|
|
256
|
+
if (target === PACKAGE_ROOT) {
|
|
257
|
+
console.log('[push-todo] Clawdbot: Symlink already configured');
|
|
258
|
+
} else {
|
|
259
|
+
unlinkSync(CLAWDBOT_SKILL_DIR);
|
|
260
|
+
symlinkSync(PACKAGE_ROOT, CLAWDBOT_SKILL_DIR);
|
|
261
|
+
console.log('[push-todo] Clawdbot: Updated symlink');
|
|
262
|
+
}
|
|
263
|
+
} else {
|
|
264
|
+
// It's a directory (old copy) - remove and replace with symlink
|
|
265
|
+
rmSync(CLAWDBOT_SKILL_DIR, { recursive: true });
|
|
266
|
+
symlinkSync(PACKAGE_ROOT, CLAWDBOT_SKILL_DIR);
|
|
267
|
+
console.log('[push-todo] Clawdbot: Replaced copy with symlink');
|
|
268
|
+
}
|
|
269
|
+
} else {
|
|
270
|
+
symlinkSync(PACKAGE_ROOT, CLAWDBOT_SKILL_DIR);
|
|
271
|
+
console.log('[push-todo] Clawdbot: Created symlink');
|
|
317
272
|
}
|
|
318
273
|
|
|
319
|
-
writeFileSync(CLAWDBOT_SKILL_FILE, SKILL_CONTENT);
|
|
320
|
-
console.log('[push-todo] Clawdbot: Created skills/push-todo/SKILL.md');
|
|
321
274
|
return true;
|
|
322
275
|
} catch (error) {
|
|
323
|
-
console.log(`[push-todo] Clawdbot:
|
|
276
|
+
console.log(`[push-todo] Clawdbot: Setup failed: ${error.message}`);
|
|
324
277
|
return false;
|
|
325
278
|
}
|
|
326
279
|
}
|