@mohitkumawat/warmup-cli 1.2.16 → 1.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/README.md +33 -10
- package/dist/commands/default.d.ts +3 -1
- package/dist/commands/default.d.ts.map +1 -1
- package/dist/commands/default.js +25 -0
- package/dist/commands/default.js.map +1 -1
- package/dist/commands/doctor.d.ts +51 -0
- package/dist/commands/doctor.d.ts.map +1 -0
- package/dist/commands/doctor.js +219 -0
- package/dist/commands/doctor.js.map +1 -0
- package/dist/commands/logs.d.ts +12 -0
- package/dist/commands/logs.d.ts.map +1 -0
- package/dist/commands/logs.js +27 -0
- package/dist/commands/logs.js.map +1 -0
- package/dist/commands/menu.d.ts +52 -0
- package/dist/commands/menu.d.ts.map +1 -0
- package/dist/commands/menu.js +185 -0
- package/dist/commands/menu.js.map +1 -0
- package/dist/commands/status.d.ts +8 -1
- package/dist/commands/status.d.ts.map +1 -1
- package/dist/commands/status.js +85 -11
- package/dist/commands/status.js.map +1 -1
- package/dist/commands/test.d.ts.map +1 -1
- package/dist/commands/test.js +25 -4
- package/dist/commands/test.js.map +1 -1
- package/dist/config.d.ts +7 -0
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +21 -0
- package/dist/config.js.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +32 -3
- package/dist/index.js.map +1 -1
- package/dist/ui.d.ts +49 -4
- package/dist/ui.d.ts.map +1 -1
- package/dist/ui.js +210 -27
- package/dist/ui.js.map +1 -1
- package/dist/warmup.d.ts +13 -4
- package/dist/warmup.d.ts.map +1 -1
- package/dist/warmup.js +139 -79
- package/dist/warmup.js.map +1 -1
- package/package.json +3 -1
package/dist/warmup.js
CHANGED
|
@@ -5,16 +5,21 @@ exports.isClaudeInstalled = isClaudeInstalled;
|
|
|
5
5
|
exports.isClaudeAuthenticated = isClaudeAuthenticated;
|
|
6
6
|
exports.getClaudeVersion = getClaudeVersion;
|
|
7
7
|
exports.executeWarmup = executeWarmup;
|
|
8
|
+
exports.executeWarmupAsync = executeWarmupAsync;
|
|
8
9
|
exports.shouldBootRecover = shouldBootRecover;
|
|
9
10
|
exports.shouldRunNearSchedule = shouldRunNearSchedule;
|
|
10
11
|
exports.shouldLogSkip = shouldLogSkip;
|
|
11
12
|
const child_process_1 = require("child_process");
|
|
12
13
|
const config_1 = require("./config");
|
|
13
14
|
const runtime_1 = require("./runtime");
|
|
15
|
+
// The checks default to the bare `claude` on PATH, but accept an explicit
|
|
16
|
+
// binary so `warmup doctor` can probe the SAME absolute path the scheduler runs
|
|
17
|
+
// (config.runtime.claudePath) — a launchd/systemd job has a minimal PATH where
|
|
18
|
+
// bare `claude` may not resolve, so probing bare `claude` could misreport.
|
|
14
19
|
/** Check if Claude Code CLI is installed */
|
|
15
|
-
function isClaudeInstalled() {
|
|
20
|
+
function isClaudeInstalled(binary = 'claude') {
|
|
16
21
|
try {
|
|
17
|
-
const result = (0, child_process_1.spawnSync)(
|
|
22
|
+
const result = (0, child_process_1.spawnSync)(binary, ['--version'], {
|
|
18
23
|
encoding: 'utf-8',
|
|
19
24
|
timeout: 10000,
|
|
20
25
|
stdio: ['pipe', 'pipe', 'pipe'],
|
|
@@ -26,9 +31,9 @@ function isClaudeInstalled() {
|
|
|
26
31
|
}
|
|
27
32
|
}
|
|
28
33
|
/** Check if Claude Code is authenticated (has valid session) */
|
|
29
|
-
function isClaudeAuthenticated() {
|
|
34
|
+
function isClaudeAuthenticated(binary = 'claude') {
|
|
30
35
|
try {
|
|
31
|
-
const result = (0, child_process_1.spawnSync)(
|
|
36
|
+
const result = (0, child_process_1.spawnSync)(binary, ['auth', 'status', '--json'], {
|
|
32
37
|
encoding: 'utf-8',
|
|
33
38
|
timeout: 10000,
|
|
34
39
|
stdio: ['pipe', 'pipe', 'pipe'],
|
|
@@ -40,9 +45,9 @@ function isClaudeAuthenticated() {
|
|
|
40
45
|
}
|
|
41
46
|
}
|
|
42
47
|
/** Get Claude Code version string */
|
|
43
|
-
function getClaudeVersion() {
|
|
48
|
+
function getClaudeVersion(binary = 'claude') {
|
|
44
49
|
try {
|
|
45
|
-
const result = (0, child_process_1.spawnSync)(
|
|
50
|
+
const result = (0, child_process_1.spawnSync)(binary, ['--version'], {
|
|
46
51
|
encoding: 'utf-8',
|
|
47
52
|
timeout: 10000,
|
|
48
53
|
stdio: ['pipe', 'pipe', 'pipe'],
|
|
@@ -56,92 +61,147 @@ function getClaudeVersion() {
|
|
|
56
61
|
return null;
|
|
57
62
|
}
|
|
58
63
|
}
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
64
|
+
const PING_ARGS = ['-p', 'ping', '--max-turns', '1'];
|
|
65
|
+
const PING_TIMEOUT_MS = 30000;
|
|
66
|
+
const pingEnv = () => ({ ...process.env, CLAUDE_NO_ANALYTICS: '1' });
|
|
67
|
+
function localTime(timezone) {
|
|
68
|
+
return new Date().toLocaleTimeString('en-US', {
|
|
69
|
+
timeZone: timezone,
|
|
70
|
+
hour: 'numeric',
|
|
71
|
+
minute: '2-digit',
|
|
72
|
+
hour12: true,
|
|
73
|
+
});
|
|
74
|
+
}
|
|
75
|
+
const dryRunResult = (isBootRecovery) => ({
|
|
76
|
+
success: true,
|
|
77
|
+
message: 'Dry run completed successfully (no request sent)',
|
|
78
|
+
duration: 5,
|
|
79
|
+
isBootRecovery,
|
|
80
|
+
});
|
|
81
|
+
/**
|
|
82
|
+
* Build + persist the outcome of a completed ping (exit code known). Shared by
|
|
83
|
+
* the sync (scheduler) and async (interactive `test`) paths so both log and
|
|
84
|
+
* report identically.
|
|
85
|
+
*/
|
|
86
|
+
function finalizeWarmup(ok, stderr, startTime, isBootRecovery, config, timezone) {
|
|
87
|
+
const duration = Date.now() - startTime;
|
|
88
|
+
if (ok) {
|
|
89
|
+
(0, config_1.writeLog)({
|
|
90
|
+
timestamp: new Date().toISOString(),
|
|
91
|
+
status: isBootRecovery ? 'boot-recovery' : 'success',
|
|
92
|
+
message: isBootRecovery
|
|
93
|
+
? 'Boot-recovery pre-warm executed (machine was off at scheduled time)'
|
|
94
|
+
: 'Pre-warm executed successfully',
|
|
95
|
+
scheduledTime: config?.schedule.time || 'unknown',
|
|
96
|
+
actualTime: localTime(timezone),
|
|
97
|
+
}, timezone);
|
|
66
98
|
return {
|
|
67
99
|
success: true,
|
|
68
|
-
message: '
|
|
69
|
-
duration
|
|
100
|
+
message: isBootRecovery ? 'Boot-recovery pre-warm sent!' : 'Pre-warm sent successfully!',
|
|
101
|
+
duration,
|
|
70
102
|
isBootRecovery,
|
|
71
103
|
};
|
|
72
104
|
}
|
|
105
|
+
const errorMsg = stderr.trim() || 'Unknown error';
|
|
106
|
+
(0, config_1.writeLog)({
|
|
107
|
+
timestamp: new Date().toISOString(),
|
|
108
|
+
status: 'failed',
|
|
109
|
+
message: `Pre-warm failed: ${errorMsg}`,
|
|
110
|
+
scheduledTime: config?.schedule.time || 'unknown',
|
|
111
|
+
actualTime: localTime(timezone),
|
|
112
|
+
}, timezone);
|
|
113
|
+
return { success: false, message: `Failed: ${errorMsg}`, duration, isBootRecovery };
|
|
114
|
+
}
|
|
115
|
+
/** Build + persist the outcome when the ping process couldn't run at all. */
|
|
116
|
+
function recordWarmupError(err, startTime, isBootRecovery, timezone) {
|
|
117
|
+
const duration = Date.now() - startTime;
|
|
118
|
+
(0, config_1.writeLog)({
|
|
119
|
+
timestamp: new Date().toISOString(),
|
|
120
|
+
status: 'failed',
|
|
121
|
+
message: `Pre-warm error: ${err.message}`,
|
|
122
|
+
}, timezone);
|
|
123
|
+
return { success: false, message: `Error: ${err.message}`, duration, isBootRecovery };
|
|
124
|
+
}
|
|
125
|
+
/**
|
|
126
|
+
* Execute the pre-warm synchronously. This is the path the OS scheduler
|
|
127
|
+
* (`_execute-warmup`) uses — it must stay blocking and side-effect-identical.
|
|
128
|
+
*/
|
|
129
|
+
function executeWarmup(isBootRecovery = false, dryRun = false) {
|
|
130
|
+
const config = (0, config_1.readConfig)();
|
|
131
|
+
const startTime = Date.now();
|
|
132
|
+
const timezone = config?.schedule.timezone || 'UTC';
|
|
133
|
+
const claudeBinary = config?.runtime?.claudePath || 'claude';
|
|
134
|
+
if (dryRun)
|
|
135
|
+
return dryRunResult(isBootRecovery);
|
|
73
136
|
try {
|
|
74
|
-
const result = (0, child_process_1.spawnSync)(claudeBinary,
|
|
137
|
+
const result = (0, child_process_1.spawnSync)(claudeBinary, PING_ARGS, {
|
|
75
138
|
encoding: 'utf-8',
|
|
76
|
-
timeout:
|
|
139
|
+
timeout: PING_TIMEOUT_MS,
|
|
77
140
|
stdio: ['pipe', 'pipe', 'pipe'],
|
|
78
|
-
env:
|
|
141
|
+
env: pingEnv(),
|
|
79
142
|
});
|
|
80
|
-
|
|
81
|
-
if (result.status === 0) {
|
|
82
|
-
const logEntry = {
|
|
83
|
-
timestamp: new Date().toISOString(),
|
|
84
|
-
status: isBootRecovery ? 'boot-recovery' : 'success',
|
|
85
|
-
message: isBootRecovery
|
|
86
|
-
? `Boot-recovery pre-warm executed (machine was off at scheduled time)`
|
|
87
|
-
: `Pre-warm executed successfully`,
|
|
88
|
-
scheduledTime: config?.schedule.time || 'unknown',
|
|
89
|
-
actualTime: new Date().toLocaleTimeString('en-US', {
|
|
90
|
-
timeZone: timezone,
|
|
91
|
-
hour: 'numeric',
|
|
92
|
-
minute: '2-digit',
|
|
93
|
-
hour12: true,
|
|
94
|
-
}),
|
|
95
|
-
};
|
|
96
|
-
(0, config_1.writeLog)(logEntry, timezone);
|
|
97
|
-
return {
|
|
98
|
-
success: true,
|
|
99
|
-
message: isBootRecovery
|
|
100
|
-
? 'Boot-recovery pre-warm sent!'
|
|
101
|
-
: 'Pre-warm sent successfully!',
|
|
102
|
-
duration,
|
|
103
|
-
isBootRecovery,
|
|
104
|
-
};
|
|
105
|
-
}
|
|
106
|
-
else {
|
|
107
|
-
const errorMsg = result.stderr?.trim() || 'Unknown error';
|
|
108
|
-
const logEntry = {
|
|
109
|
-
timestamp: new Date().toISOString(),
|
|
110
|
-
status: 'failed',
|
|
111
|
-
message: `Pre-warm failed: ${errorMsg}`,
|
|
112
|
-
scheduledTime: config?.schedule.time || 'unknown',
|
|
113
|
-
actualTime: new Date().toLocaleTimeString('en-US', {
|
|
114
|
-
timeZone: timezone,
|
|
115
|
-
hour: 'numeric',
|
|
116
|
-
minute: '2-digit',
|
|
117
|
-
hour12: true,
|
|
118
|
-
}),
|
|
119
|
-
};
|
|
120
|
-
(0, config_1.writeLog)(logEntry, timezone);
|
|
121
|
-
return {
|
|
122
|
-
success: false,
|
|
123
|
-
message: `Failed: ${errorMsg}`,
|
|
124
|
-
duration,
|
|
125
|
-
isBootRecovery,
|
|
126
|
-
};
|
|
127
|
-
}
|
|
143
|
+
return finalizeWarmup(result.status === 0, result.stderr || '', startTime, isBootRecovery, config, timezone);
|
|
128
144
|
}
|
|
129
145
|
catch (err) {
|
|
130
|
-
|
|
131
|
-
const logEntry = {
|
|
132
|
-
timestamp: new Date().toISOString(),
|
|
133
|
-
status: 'failed',
|
|
134
|
-
message: `Pre-warm error: ${err.message}`,
|
|
135
|
-
};
|
|
136
|
-
(0, config_1.writeLog)(logEntry, timezone);
|
|
137
|
-
return {
|
|
138
|
-
success: false,
|
|
139
|
-
message: `Error: ${err.message}`,
|
|
140
|
-
duration,
|
|
141
|
-
isBootRecovery,
|
|
142
|
-
};
|
|
146
|
+
return recordWarmupError(err, startTime, isBootRecovery, timezone);
|
|
143
147
|
}
|
|
144
148
|
}
|
|
149
|
+
/**
|
|
150
|
+
* Execute the pre-warm asynchronously (non-blocking) so an interactive caller
|
|
151
|
+
* can animate a live spinner tied to the REAL ping latency. Used by `warmup
|
|
152
|
+
* test`; the scheduler keeps the sync path above. Logs/reports identically.
|
|
153
|
+
*/
|
|
154
|
+
function executeWarmupAsync(isBootRecovery = false, dryRun = false) {
|
|
155
|
+
const config = (0, config_1.readConfig)();
|
|
156
|
+
const startTime = Date.now();
|
|
157
|
+
const timezone = config?.schedule.timezone || 'UTC';
|
|
158
|
+
const claudeBinary = config?.runtime?.claudePath || 'claude';
|
|
159
|
+
if (dryRun)
|
|
160
|
+
return Promise.resolve(dryRunResult(isBootRecovery));
|
|
161
|
+
return new Promise((resolve) => {
|
|
162
|
+
let settled = false;
|
|
163
|
+
let stderr = '';
|
|
164
|
+
let timer;
|
|
165
|
+
// Settle exactly once. The log-writing side effect lives INSIDE the guard
|
|
166
|
+
// (build is only invoked when we actually settle) so a late 'close' after a
|
|
167
|
+
// kill/error can't write a second log entry.
|
|
168
|
+
const settle = (build) => {
|
|
169
|
+
if (settled)
|
|
170
|
+
return;
|
|
171
|
+
settled = true;
|
|
172
|
+
if (timer)
|
|
173
|
+
clearTimeout(timer);
|
|
174
|
+
resolve(build());
|
|
175
|
+
};
|
|
176
|
+
let child;
|
|
177
|
+
try {
|
|
178
|
+
child = (0, child_process_1.spawn)(claudeBinary, PING_ARGS, { stdio: ['pipe', 'pipe', 'pipe'], env: pingEnv() });
|
|
179
|
+
}
|
|
180
|
+
catch (err) {
|
|
181
|
+
// Synchronous spawn throw — mirrors the sync path's catch.
|
|
182
|
+
settle(() => recordWarmupError(err, startTime, isBootRecovery, timezone));
|
|
183
|
+
return;
|
|
184
|
+
}
|
|
185
|
+
// Mirror spawnSync semantics: give the child immediate stdin EOF (else
|
|
186
|
+
// `claude` waits ~3s for stdin) and drain stdout (else a >64KB write could
|
|
187
|
+
// back-pressure and never close). stderr is captured for the failure path.
|
|
188
|
+
child.stdin?.end();
|
|
189
|
+
child.stdout?.resume();
|
|
190
|
+
child.stderr?.on('data', (chunk) => { stderr += chunk.toString(); });
|
|
191
|
+
timer = setTimeout(() => {
|
|
192
|
+
// Route through finalizeWarmup so the log entry matches the sync path
|
|
193
|
+
// (status 'failed' + scheduledTime/actualTime + "Pre-warm failed:" wording).
|
|
194
|
+
settle(() => finalizeWarmup(false, 'Timed out after 30s', startTime, isBootRecovery, config, timezone));
|
|
195
|
+
try {
|
|
196
|
+
child.kill('SIGKILL');
|
|
197
|
+
}
|
|
198
|
+
catch { /* already exited */ }
|
|
199
|
+
child.unref(); // don't keep the event loop alive if the kill is slow
|
|
200
|
+
}, PING_TIMEOUT_MS);
|
|
201
|
+
child.on('error', (err) => settle(() => finalizeWarmup(false, err.message, startTime, isBootRecovery, config, timezone)));
|
|
202
|
+
child.on('close', (code) => settle(() => finalizeWarmup(code === 0, stderr, startTime, isBootRecovery, config, timezone)));
|
|
203
|
+
});
|
|
204
|
+
}
|
|
145
205
|
/**
|
|
146
206
|
* Boot-recovery check: determine if we should fire a pre-warm now
|
|
147
207
|
* because the scheduled time was missed (machine was off).
|
package/dist/warmup.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"warmup.js","sourceRoot":"","sources":["../src/warmup.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"warmup.js","sourceRoot":"","sources":["../src/warmup.ts"],"names":[],"mappings":";;;AAkBA,8CAWC;AAGD,sDAYC;AAGD,4CAcC;AA+FD,sCAmBC;AAOD,gDAqDC;AAYD,8CAsBC;AAsBD,sDAcC;AAaD,sCA2BC;AAzVD,iDAAiD;AACjD,qCAQkB;AAClB,uCAAkD;AAElD,0EAA0E;AAC1E,gFAAgF;AAChF,+EAA+E;AAC/E,2EAA2E;AAE3E,4CAA4C;AAC5C,SAAgB,iBAAiB,CAAC,SAAiB,QAAQ;IACzD,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,IAAA,yBAAS,EAAC,MAAM,EAAE,CAAC,WAAW,CAAC,EAAE;YAC9C,QAAQ,EAAE,OAAO;YACjB,OAAO,EAAE,KAAK;YACd,KAAK,EAAE,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC;SAChC,CAAC,CAAC;QACH,OAAO,MAAM,CAAC,MAAM,KAAK,CAAC,CAAC;IAC7B,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,KAAK,CAAC;IACf,CAAC;AAC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CAAC,IAAA,wBAAe,EAAC,6BAA6B,CAAC,CAAC;AACzD,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mohitkumawat/warmup-cli",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.3.0",
|
|
4
4
|
"description": "Pre-warm your Claude rate limits while you sleep. One command, zero daily effort.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"bin": {
|
|
@@ -38,12 +38,14 @@
|
|
|
38
38
|
"figures": "^3.2.0",
|
|
39
39
|
"gradient-string": "^2.0.2",
|
|
40
40
|
"inquirer": "^8.2.6",
|
|
41
|
+
"inquirer-autocomplete-prompt": "^2.0.1",
|
|
41
42
|
"ora": "^5.4.1",
|
|
42
43
|
"string-width": "^4.2.3"
|
|
43
44
|
},
|
|
44
45
|
"devDependencies": {
|
|
45
46
|
"@types/gradient-string": "^1.1.6",
|
|
46
47
|
"@types/inquirer": "^8.2.10",
|
|
48
|
+
"@types/inquirer-autocomplete-prompt": "^3.0.3",
|
|
47
49
|
"@types/node": "^20.11.0",
|
|
48
50
|
"ts-node": "^10.9.2",
|
|
49
51
|
"typescript": "^5.3.3"
|