@mohitkumawat/warmup-cli 1.1.3 → 1.2.1
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 +64 -45
- package/dist/commands/default.d.ts +19 -0
- package/dist/commands/default.d.ts.map +1 -0
- package/dist/commands/default.js +49 -0
- package/dist/commands/default.js.map +1 -0
- package/dist/commands/setup.d.ts +47 -1
- package/dist/commands/setup.d.ts.map +1 -1
- package/dist/commands/setup.js +75 -57
- package/dist/commands/setup.js.map +1 -1
- package/dist/commands/update.d.ts.map +1 -1
- package/dist/commands/update.js +47 -66
- package/dist/commands/update.js.map +1 -1
- package/dist/config.d.ts +1 -0
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +4 -0
- package/dist/config.js.map +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +68 -99
- package/dist/index.js.map +1 -1
- package/dist/scheduler/index.d.ts +1 -0
- package/dist/scheduler/index.d.ts.map +1 -1
- package/dist/scheduler/index.js +17 -0
- package/dist/scheduler/index.js.map +1 -1
- package/dist/scheduler/linux.d.ts +3 -2
- package/dist/scheduler/linux.d.ts.map +1 -1
- package/dist/scheduler/linux.js +12 -1
- package/dist/scheduler/linux.js.map +1 -1
- package/dist/ui.d.ts +38 -0
- package/dist/ui.d.ts.map +1 -1
- package/dist/ui.js +322 -123
- package/dist/ui.js.map +1 -1
- package/package.json +3 -2
package/README.md
CHANGED
|
@@ -1,11 +1,14 @@
|
|
|
1
|
+
<div align="center">
|
|
2
|
+
|
|
1
3
|
# ☕ warmup
|
|
2
4
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
+
**Pre-warm your Claude rate limits while you sleep.**<br>
|
|
6
|
+
*One command. Zero daily effort. Full Claude capacity when you need it.*
|
|
5
7
|
|
|
6
|
-
|
|
8
|
+
[](https://www.npmjs.com/package/@mohitkumawat/warmup-cli)
|
|
9
|
+
[](https://opensource.org/licenses/MIT)
|
|
7
10
|
|
|
8
|
-
|
|
11
|
+
</div>
|
|
9
12
|
|
|
10
13
|
---
|
|
11
14
|
|
|
@@ -15,21 +18,20 @@ Claude Pro and Max subscribers share a **5-hour rolling rate limit window** acro
|
|
|
15
18
|
|
|
16
19
|
## 🟢 The Solution
|
|
17
20
|
|
|
18
|
-
|
|
21
|
+
**`warmup`** starts your rate limit window _before_ you wake up by scheduling one tiny Claude Code ping (~10 tokens) at the exact right time.
|
|
19
22
|
|
|
20
23
|
By the time you sit down to work, the window is perfectly timed to expire exactly when you need it, granting you a **100% fresh allocation** right in the middle of your workday.
|
|
21
24
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
```
|
|
25
|
+
> **Without warmup:**
|
|
26
|
+
> 10:00 AM → You start working, window starts.
|
|
27
|
+
> 12:00 PM → Rate limited! Must wait until 3:00 PM.
|
|
28
|
+
>
|
|
29
|
+
> **With warmup (2-hour exhaustion):**
|
|
30
|
+
> 7:00 AM → warmup sends one tiny ping (window starts).
|
|
31
|
+
> 10:00 AM → You start working using the active window.
|
|
32
|
+
> 12:00 PM → You exhaust your limits, BUT the 7:00 AM window ends right now!
|
|
33
|
+
> 12:00 PM → Window resets instantly. Full capacity continues.
|
|
34
|
+
|
|
33
35
|
*You just saved 3 hours of waiting.*
|
|
34
36
|
|
|
35
37
|
---
|
|
@@ -39,24 +41,35 @@ By the time you sit down to work, the window is perfectly timed to expire exactl
|
|
|
39
41
|
```bash
|
|
40
42
|
npm install -g @mohitkumawat/warmup-cli
|
|
41
43
|
```
|
|
44
|
+
*Prerequisites: [Claude Code](https://code.claude.com) must be installed and authenticated.*
|
|
42
45
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
## 🧠 Smart Setup
|
|
46
|
-
|
|
47
|
-
We don't ask you to do modulo-math to figure out your 5-hour window. `warmup` uses a **Smart Scheduler**.
|
|
46
|
+
## 🚀 Quick Start
|
|
48
47
|
|
|
49
48
|
```bash
|
|
50
|
-
warmup
|
|
49
|
+
warmup
|
|
51
50
|
```
|
|
52
51
|
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
52
|
+
Fresh installs open a **guided onboarding wizard**.
|
|
53
|
+
|
|
54
|
+
### 🔍 What happens
|
|
55
|
+
* Shows the exact background command (`claude -p ping --max-turns 1`) transparently.
|
|
56
|
+
* Asks about your typical work schedule.
|
|
57
|
+
* Shows a detailed geometric preview of the scheduled timeline before explicitly asking for confirmation.
|
|
58
|
+
* Stores config and logs purely locally in `~/.warmup/`.
|
|
56
59
|
|
|
57
|
-
|
|
60
|
+
### 🛡 What DOES NOT happen
|
|
61
|
+
* Setup does **not** send a live Claude request or burn any limits.
|
|
62
|
+
* `warmup` does **not** proxy your session, extract tokens, or phone home to any backend api.
|
|
58
63
|
|
|
59
|
-
|
|
64
|
+
---
|
|
65
|
+
|
|
66
|
+
## 🧠 Smart Setup
|
|
67
|
+
|
|
68
|
+
We don't ask you to do modulo-math to figure out your 5-hour window. `warmup` asks you two plain-English questions:
|
|
69
|
+
1. **When do you start working?** (e.g., 9:00 AM)
|
|
70
|
+
2. **How quickly do you exhaust limits?** (e.g., 1-2 hours)
|
|
71
|
+
|
|
72
|
+
It then automatically calculates the **exact optimal pre-warm time** to ensure your rate limit resets exactly the minute you run out of messages.
|
|
60
73
|
|
|
61
74
|
## 🛡️ Bulletproof Boot-Recovery
|
|
62
75
|
|
|
@@ -64,12 +77,13 @@ That's it. The OS scheduler installs it in the background. You'll never touch it
|
|
|
64
77
|
|
|
65
78
|
`warmup` handles this automatically using native OS features. If your laptop was closed at your 5:00 AM pre-warm time, the pre-warm fires **immediately upon waking your machine** (e.g., at 8:00 AM).
|
|
66
79
|
|
|
67
|
-
It has built-in deduplication guards
|
|
80
|
+
It has built-in deduplication guards: it will *never* double-fire or accidentally consume a second rate-limit window, even if you restart your computer 10 times a day.
|
|
68
81
|
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
82
|
+
* **macOS:** `launchd` via `RunAtLoad`
|
|
83
|
+
* **Linux:** `systemd` timers via `Persistent=true`
|
|
84
|
+
* **Windows:** `schtasks` via `StartWhenAvailable`
|
|
85
|
+
|
|
86
|
+
---
|
|
73
87
|
|
|
74
88
|
## 🛠️ Commands
|
|
75
89
|
|
|
@@ -83,25 +97,30 @@ Supported universally:
|
|
|
83
97
|
| `warmup resume` | Resume the daily schedule |
|
|
84
98
|
| `warmup uninstall` | Remove the background task |
|
|
85
99
|
|
|
100
|
+
---
|
|
86
101
|
|
|
87
102
|
## ❓ FAQ
|
|
88
103
|
|
|
89
|
-
|
|
90
|
-
|
|
104
|
+
<details>
|
|
105
|
+
<summary><b>Is this ToS-compliant?</b></summary>
|
|
106
|
+
<br>
|
|
107
|
+
Yes. The request goes strictly through the official Claude Code CLI using your local authenticated session. We never extract, store, or proxy your OAuth token. This is functionally identical to you typing a message into the CLI yourself.
|
|
108
|
+
</details>
|
|
91
109
|
|
|
92
|
-
|
|
110
|
+
<details>
|
|
111
|
+
<summary><b>Does this work for claude.ai web chat?</b></summary>
|
|
112
|
+
<br>
|
|
93
113
|
Yes! The subscription rate limit pool is shared across claude.ai, Claude Code, and Cowork. Pre-warming through the CLI grants you limits on the web interface too.
|
|
114
|
+
</details>
|
|
94
115
|
|
|
95
|
-
|
|
116
|
+
<details>
|
|
117
|
+
<summary><b>What if I travel to a different timezone?</b></summary>
|
|
118
|
+
<br>
|
|
96
119
|
Run `warmup update`. Your new timezone is auto-detected.
|
|
97
|
-
|
|
98
|
-
## 🗑️ Uninstall
|
|
99
|
-
|
|
100
|
-
```bash
|
|
101
|
-
warmup uninstall # removes the OS background task
|
|
102
|
-
npm uninstall -g warmup-cli # removes the package
|
|
103
|
-
```
|
|
120
|
+
</details>
|
|
104
121
|
|
|
105
122
|
---
|
|
106
|
-
|
|
107
|
-
|
|
123
|
+
|
|
124
|
+
<div align="center">
|
|
125
|
+
<sub>Built with ❤️ by Mohit. MIT License.</sub>
|
|
126
|
+
</div>
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { readConfig } from '../config';
|
|
2
|
+
import { type SetupCommandOptions } from './setup';
|
|
3
|
+
interface OnboardingDependencies {
|
|
4
|
+
confirmStartSetup: () => Promise<boolean>;
|
|
5
|
+
printLogo: () => void;
|
|
6
|
+
printFirstRunIntro: () => void;
|
|
7
|
+
printSetupTransparency: () => void;
|
|
8
|
+
printSetupDeferred: () => void;
|
|
9
|
+
runSetup: (options?: SetupCommandOptions) => Promise<void>;
|
|
10
|
+
}
|
|
11
|
+
interface DefaultCommandDependencies {
|
|
12
|
+
readConfig: typeof readConfig;
|
|
13
|
+
runStatus: () => Promise<void>;
|
|
14
|
+
runFirstRunOnboarding: () => Promise<void>;
|
|
15
|
+
}
|
|
16
|
+
export declare function runFirstRunOnboarding(deps?: Partial<OnboardingDependencies>): Promise<void>;
|
|
17
|
+
export declare function defaultCommand(deps?: Partial<DefaultCommandDependencies>): Promise<'status' | 'onboarding'>;
|
|
18
|
+
export {};
|
|
19
|
+
//# sourceMappingURL=default.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"default.d.ts","sourceRoot":"","sources":["../../src/commands/default.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAOvC,OAAO,EAAgB,KAAK,mBAAmB,EAAE,MAAM,SAAS,CAAC;AAGjE,UAAU,sBAAsB;IAC9B,iBAAiB,EAAE,MAAM,OAAO,CAAC,OAAO,CAAC,CAAC;IAC1C,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB,kBAAkB,EAAE,MAAM,IAAI,CAAC;IAC/B,sBAAsB,EAAE,MAAM,IAAI,CAAC;IACnC,kBAAkB,EAAE,MAAM,IAAI,CAAC;IAC/B,QAAQ,EAAE,CAAC,OAAO,CAAC,EAAE,mBAAmB,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;CAC5D;AAED,UAAU,0BAA0B;IAClC,UAAU,EAAE,OAAO,UAAU,CAAC;IAC9B,SAAS,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IAC/B,qBAAqB,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;CAC5C;AAaD,wBAAsB,qBAAqB,CACzC,IAAI,GAAE,OAAO,CAAC,sBAAsB,CAAM,GACzC,OAAO,CAAC,IAAI,CAAC,CAkBf;AAED,wBAAsB,cAAc,CAClC,IAAI,GAAE,OAAO,CAAC,0BAA0B,CAAM,GAC7C,OAAO,CAAC,QAAQ,GAAG,YAAY,CAAC,CAYlC"}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.runFirstRunOnboarding = runFirstRunOnboarding;
|
|
7
|
+
exports.defaultCommand = defaultCommand;
|
|
8
|
+
const inquirer_1 = __importDefault(require("inquirer"));
|
|
9
|
+
const config_1 = require("../config");
|
|
10
|
+
const ui_1 = require("../ui");
|
|
11
|
+
const setup_1 = require("./setup");
|
|
12
|
+
const status_1 = require("./status");
|
|
13
|
+
async function promptToStartSetup() {
|
|
14
|
+
const { startSetup } = await inquirer_1.default.prompt([{
|
|
15
|
+
type: 'confirm',
|
|
16
|
+
name: 'startSetup',
|
|
17
|
+
message: 'Start setup now?',
|
|
18
|
+
default: true,
|
|
19
|
+
}]);
|
|
20
|
+
return startSetup;
|
|
21
|
+
}
|
|
22
|
+
async function runFirstRunOnboarding(deps = {}) {
|
|
23
|
+
const confirmStartSetup = deps.confirmStartSetup ?? promptToStartSetup;
|
|
24
|
+
const showLogo = deps.printLogo ?? ui_1.printLogo;
|
|
25
|
+
const showFirstRunIntro = deps.printFirstRunIntro ?? ui_1.printFirstRunIntro;
|
|
26
|
+
const showSetupTransparency = deps.printSetupTransparency ?? ui_1.printSetupTransparency;
|
|
27
|
+
const showSetupDeferred = deps.printSetupDeferred ?? ui_1.printSetupDeferred;
|
|
28
|
+
const runSetup = deps.runSetup ?? setup_1.setupCommand;
|
|
29
|
+
showLogo();
|
|
30
|
+
showFirstRunIntro();
|
|
31
|
+
showSetupTransparency();
|
|
32
|
+
if (!(await confirmStartSetup())) {
|
|
33
|
+
showSetupDeferred();
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
await runSetup({ skipLogo: true });
|
|
37
|
+
}
|
|
38
|
+
async function defaultCommand(deps = {}) {
|
|
39
|
+
const loadConfig = deps.readConfig ?? config_1.readConfig;
|
|
40
|
+
const runStatus = deps.runStatus ?? status_1.statusCommand;
|
|
41
|
+
const runOnboarding = deps.runFirstRunOnboarding ?? runFirstRunOnboarding;
|
|
42
|
+
if (loadConfig()) {
|
|
43
|
+
await runStatus();
|
|
44
|
+
return 'status';
|
|
45
|
+
}
|
|
46
|
+
await runOnboarding();
|
|
47
|
+
return 'onboarding';
|
|
48
|
+
}
|
|
49
|
+
//# sourceMappingURL=default.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"default.js","sourceRoot":"","sources":["../../src/commands/default.ts"],"names":[],"mappings":";;;;;AAqCA,sDAoBC;AAED,wCAcC;AAzED,wDAAgC;AAChC,sCAAuC;AACvC,8BAKe;AACf,mCAAiE;AACjE,qCAAyC;AAiBzC,KAAK,UAAU,kBAAkB;IAC/B,MAAM,EAAE,UAAU,EAAE,GAAG,MAAM,kBAAQ,CAAC,MAAM,CAAC,CAAC;YAC5C,IAAI,EAAE,SAAS;YACf,IAAI,EAAE,YAAY;YAClB,OAAO,EAAE,kBAAkB;YAC3B,OAAO,EAAE,IAAI;SACd,CAAC,CAAC,CAAC;IAEJ,OAAO,UAAU,CAAC;AACpB,CAAC;AAEM,KAAK,UAAU,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
|
3
|
+
import { type RuntimePaths } from '../runtime';
|
|
4
|
+
export interface SetupCommandOptions {
|
|
5
|
+
skipLogo?: boolean;
|
|
6
|
+
}
|
|
7
|
+
export interface SetupInstallPlan extends InstallPreviewContent {
|
|
8
|
+
time: string;
|
|
9
|
+
hour: number;
|
|
10
|
+
minute: number;
|
|
11
|
+
}
|
|
12
|
+
interface SpinnerLike {
|
|
13
|
+
succeed(text: string): void;
|
|
14
|
+
fail(text: string): void;
|
|
15
|
+
}
|
|
16
|
+
interface ConfirmAndInstallDependencies {
|
|
17
|
+
printInstallPreview: (preview: InstallPreviewContent) => void;
|
|
18
|
+
confirmInstall: () => Promise<boolean>;
|
|
19
|
+
printSetupDeferred: () => void;
|
|
20
|
+
createInstallSpinner: (schedulerLabel: string) => SpinnerLike;
|
|
21
|
+
ensureConfigDir: () => void;
|
|
22
|
+
resolveRuntimePaths: () => RuntimePaths;
|
|
23
|
+
installSchedule: (options: {
|
|
24
|
+
hour: number;
|
|
25
|
+
minute: number;
|
|
26
|
+
runtime: RuntimePaths;
|
|
27
|
+
}) => void;
|
|
28
|
+
createDefaultConfig: (time: string, timezone: string, runtime: RuntimePaths) => WarmupConfig;
|
|
29
|
+
writeConfig: (config: WarmupConfig) => void;
|
|
30
|
+
animateSetupComplete: (config: WarmupConfig) => Promise<void>;
|
|
31
|
+
}
|
|
32
|
+
/** Generate choices for work start time (30 min increments) */
|
|
33
|
+
export declare function generateStartTimeChoices(): Array<{
|
|
34
|
+
name: string;
|
|
35
|
+
value: number;
|
|
36
|
+
}>;
|
|
37
|
+
/** Calculate the optimal pre-warm time based on user feedback */
|
|
38
|
+
export declare function calculateOptimalPrewarm(startMins: number, exhaustMins: number): {
|
|
39
|
+
time: string;
|
|
40
|
+
h: number;
|
|
41
|
+
m: number;
|
|
42
|
+
explanation: string;
|
|
43
|
+
};
|
|
44
|
+
export declare function buildSetupInstallPlan(startMins: number, exhaustMins: number, timezone: string, overrides?: Partial<Pick<SetupInstallPlan, 'schedulerLabel' | 'note'>>): SetupInstallPlan;
|
|
45
|
+
export declare function confirmAndInstallSchedule(plan: SetupInstallPlan, deps?: Partial<ConfirmAndInstallDependencies>): Promise<'cancelled' | 'installed' | 'failed'>;
|
|
46
|
+
export declare function setupCommand(options?: SetupCommandOptions): Promise<void>;
|
|
47
|
+
export {};
|
|
2
48
|
//# sourceMappingURL=setup.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"setup.d.ts","sourceRoot":"","sources":["../../src/commands/setup.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"setup.d.ts","sourceRoot":"","sources":["../../src/commands/setup.ts"],"names":[],"mappings":"AAGA,OAAO,EAOL,YAAY,EACb,MAAM,WAAW,CAAC;AAGnB,OAAO,EAQL,KAAK,qBAAqB,EAC3B,MAAM,OAAO,CAAC;AACf,OAAO,EAAuB,KAAK,YAAY,EAAE,MAAM,YAAY,CAAC;AAKpE,MAAM,WAAW,mBAAmB;IAClC,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,MAAM,WAAW,gBAAiB,SAAQ,qBAAqB;IAC7D,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,UAAU,WAAW;IACnB,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,IAAI,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;CAC1B;AAED,UAAU,6BAA6B;IACrC,mBAAmB,EAAE,CAAC,OAAO,EAAE,qBAAqB,KAAK,IAAI,CAAC;IAC9D,cAAc,EAAE,MAAM,OAAO,CAAC,OAAO,CAAC,CAAC;IACvC,kBAAkB,EAAE,MAAM,IAAI,CAAC;IAC/B,oBAAoB,EAAE,CAAC,cAAc,EAAE,MAAM,KAAK,WAAW,CAAC;IAC9D,eAAe,EAAE,MAAM,IAAI,CAAC;IAC5B,mBAAmB,EAAE,MAAM,YA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"}
|
package/dist/commands/setup.js
CHANGED
|
@@ -3,6 +3,10 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.generateStartTimeChoices = generateStartTimeChoices;
|
|
7
|
+
exports.calculateOptimalPrewarm = calculateOptimalPrewarm;
|
|
8
|
+
exports.buildSetupInstallPlan = buildSetupInstallPlan;
|
|
9
|
+
exports.confirmAndInstallSchedule = confirmAndInstallSchedule;
|
|
6
10
|
exports.setupCommand = setupCommand;
|
|
7
11
|
const inquirer_1 = __importDefault(require("inquirer"));
|
|
8
12
|
const chalk_1 = __importDefault(require("chalk"));
|
|
@@ -25,7 +29,6 @@ function generateStartTimeChoices() {
|
|
|
25
29
|
const label = `${h12}:${mStr} ${period}`;
|
|
26
30
|
const minutesSinceMidnight = h * 60 + m;
|
|
27
31
|
let suffix = '';
|
|
28
|
-
// typical work start times
|
|
29
32
|
if (h === 9 && m === 0)
|
|
30
33
|
suffix = ' ← standard';
|
|
31
34
|
if (h === 10 && m === 0)
|
|
@@ -40,16 +43,10 @@ function generateStartTimeChoices() {
|
|
|
40
43
|
}
|
|
41
44
|
/** Calculate the optimal pre-warm time based on user feedback */
|
|
42
45
|
function calculateOptimalPrewarm(startMins, exhaustMins) {
|
|
43
|
-
// We want the 5-hour window to end EXACTLY when they exhaust their limits.
|
|
44
|
-
// Window End = Start Time + Exhaustion Time
|
|
45
|
-
// Pre-warm Time = Window End - 5 hours
|
|
46
46
|
let prewarmMins = startMins + exhaustMins - (5 * 60);
|
|
47
|
-
// If exhaust time > 5 hours, pre-warm time would be *after* start time, which defeats the purpose.
|
|
48
|
-
// Cap it so pre-warm is at absolute maximum their start time.
|
|
49
47
|
if (prewarmMins > startMins) {
|
|
50
48
|
prewarmMins = startMins;
|
|
51
49
|
}
|
|
52
|
-
// Handle midnight wraparound
|
|
53
50
|
if (prewarmMins < 0) {
|
|
54
51
|
prewarmMins += 24 * 60;
|
|
55
52
|
}
|
|
@@ -63,9 +60,71 @@ function calculateOptimalPrewarm(startMins, exhaustMins) {
|
|
|
63
60
|
const explanation = `To ensure your rate limit window resets completely at ${resetStr} exactly when you run out, we'll run the pre-warm at ${(0, config_1.formatHour)(h, m)}.`;
|
|
64
61
|
return { time: timeStr, h, m, explanation };
|
|
65
62
|
}
|
|
66
|
-
|
|
67
|
-
(
|
|
68
|
-
|
|
63
|
+
function buildSetupInstallPlan(startMins, exhaustMins, timezone, overrides = {}) {
|
|
64
|
+
const { time, h, m, explanation } = calculateOptimalPrewarm(startMins, exhaustMins);
|
|
65
|
+
return {
|
|
66
|
+
explanation,
|
|
67
|
+
time,
|
|
68
|
+
hour: h,
|
|
69
|
+
minute: m,
|
|
70
|
+
warmTime: (0, config_1.formatHour)(h, m),
|
|
71
|
+
timezone,
|
|
72
|
+
resetTime: (0, config_1.formatHour)((h + 5) % 24, m),
|
|
73
|
+
schedulerLabel: overrides.schedulerLabel ?? (0, scheduler_1.getSchedulerName)(),
|
|
74
|
+
note: overrides.note,
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
async function promptToConfirmInstall() {
|
|
78
|
+
const { confirm } = await inquirer_1.default.prompt([{
|
|
79
|
+
type: 'confirm',
|
|
80
|
+
name: 'confirm',
|
|
81
|
+
message: 'Install this schedule?',
|
|
82
|
+
default: true,
|
|
83
|
+
}]);
|
|
84
|
+
return confirm;
|
|
85
|
+
}
|
|
86
|
+
function createInstallSpinner(schedulerLabel) {
|
|
87
|
+
return (0, ora_1.default)({
|
|
88
|
+
text: `Installing schedule (${schedulerLabel})...`,
|
|
89
|
+
color: 'magenta',
|
|
90
|
+
}).start();
|
|
91
|
+
}
|
|
92
|
+
async function confirmAndInstallSchedule(plan, deps = {}) {
|
|
93
|
+
const showInstallPreview = deps.printInstallPreview ?? ui_1.printInstallPreview;
|
|
94
|
+
const confirmInstall = deps.confirmInstall ?? promptToConfirmInstall;
|
|
95
|
+
const showSetupDeferred = deps.printSetupDeferred ?? ui_1.printSetupDeferred;
|
|
96
|
+
const startInstallSpinner = deps.createInstallSpinner ?? createInstallSpinner;
|
|
97
|
+
const ensureDir = deps.ensureConfigDir ?? config_1.ensureConfigDir;
|
|
98
|
+
const resolveRuntime = deps.resolveRuntimePaths ?? runtime_1.resolveRuntimePaths;
|
|
99
|
+
const install = deps.installSchedule ?? scheduler_1.installSchedule;
|
|
100
|
+
const makeConfig = deps.createDefaultConfig ?? config_1.createDefaultConfig;
|
|
101
|
+
const persistConfig = deps.writeConfig ?? config_1.writeConfig;
|
|
102
|
+
const finishSetup = deps.animateSetupComplete ?? ui_1.animateSetupComplete;
|
|
103
|
+
showInstallPreview(plan);
|
|
104
|
+
if (!(await confirmInstall())) {
|
|
105
|
+
showSetupDeferred();
|
|
106
|
+
return 'cancelled';
|
|
107
|
+
}
|
|
108
|
+
const installSpinner = startInstallSpinner(plan.schedulerLabel);
|
|
109
|
+
try {
|
|
110
|
+
ensureDir();
|
|
111
|
+
const runtime = resolveRuntime();
|
|
112
|
+
install({ hour: plan.hour, minute: plan.minute, runtime });
|
|
113
|
+
const config = makeConfig(plan.time, plan.timezone, runtime);
|
|
114
|
+
persistConfig(config);
|
|
115
|
+
installSpinner.succeed('Schedule installed with boot-recovery');
|
|
116
|
+
await finishSetup(config);
|
|
117
|
+
return 'installed';
|
|
118
|
+
}
|
|
119
|
+
catch (err) {
|
|
120
|
+
installSpinner.fail(`Installation failed: ${err.message}`);
|
|
121
|
+
return 'failed';
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
async function setupCommand(options = {}) {
|
|
125
|
+
if (!options.skipLogo) {
|
|
126
|
+
(0, ui_1.printLogo)();
|
|
127
|
+
}
|
|
69
128
|
const existing = (0, config_1.readConfig)();
|
|
70
129
|
if (existing) {
|
|
71
130
|
(0, ui_1.printAlreadySetup)(existing);
|
|
@@ -78,7 +137,7 @@ async function setupCommand() {
|
|
|
78
137
|
if (!overwrite)
|
|
79
138
|
return;
|
|
80
139
|
}
|
|
81
|
-
|
|
140
|
+
(0, ui_1.printSetupTransparency)();
|
|
82
141
|
const spinner = (0, ora_1.default)({
|
|
83
142
|
text: 'Checking for Claude Code...',
|
|
84
143
|
color: 'magenta',
|
|
@@ -89,7 +148,6 @@ async function setupCommand() {
|
|
|
89
148
|
return;
|
|
90
149
|
}
|
|
91
150
|
spinner.succeed('Claude Code detected');
|
|
92
|
-
// Check authentication
|
|
93
151
|
const authSpinner = (0, ora_1.default)({
|
|
94
152
|
text: 'Checking Claude Code authentication...',
|
|
95
153
|
color: 'magenta',
|
|
@@ -101,11 +159,9 @@ async function setupCommand() {
|
|
|
101
159
|
return;
|
|
102
160
|
}
|
|
103
161
|
authSpinner.succeed('Claude Code authenticated');
|
|
104
|
-
// Detect timezone
|
|
105
162
|
const timezone = (0, config_1.detectTimezone)();
|
|
106
163
|
console.log(` ${DIM('Timezone:')} ${ACCENT(timezone)} ${DIM('(auto-detected)')}`);
|
|
107
164
|
console.log('');
|
|
108
|
-
// Smart Scheduler Questionnaire
|
|
109
165
|
console.log(chalk_1.default.cyan(' Let\'s optimize your schedule based on your typical usage.'));
|
|
110
166
|
console.log('');
|
|
111
167
|
const { startMins } = await inquirer_1.default.prompt([{
|
|
@@ -113,7 +169,7 @@ async function setupCommand() {
|
|
|
113
169
|
name: 'startMins',
|
|
114
170
|
message: 'When do you usually start your heavy Claude usage each day?',
|
|
115
171
|
choices: generateStartTimeChoices(),
|
|
116
|
-
default: 9 * 60,
|
|
172
|
+
default: 9 * 60,
|
|
117
173
|
pageSize: 12,
|
|
118
174
|
}]);
|
|
119
175
|
const { exhaustMins } = await inquirer_1.default.prompt([{
|
|
@@ -125,49 +181,11 @@ async function setupCommand() {
|
|
|
125
181
|
{ name: '1-2 hours', value: 120 },
|
|
126
182
|
{ name: '2-3 hours', value: 180 },
|
|
127
183
|
{ name: '3-4 hours', value: 240 },
|
|
128
|
-
{ name: 'I rarely hit the limit / 5+ hours', value: 300 }
|
|
184
|
+
{ name: 'I rarely hit the limit / 5+ hours', value: 300 },
|
|
129
185
|
],
|
|
130
|
-
default: 120,
|
|
186
|
+
default: 120,
|
|
131
187
|
}]);
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
const resetH = (h + 5) % 24;
|
|
135
|
-
console.log('');
|
|
136
|
-
console.log(` ${chalk_1.default.bgCyan.black(' OPTIMAL SCHEDULE ')}`);
|
|
137
|
-
console.log(` ${chalk_1.default.cyan('💡')} ${DIM(explanation)}`);
|
|
138
|
-
console.log('');
|
|
139
|
-
console.log(` ${DIM('Pre-warm at:')} ${ACCENT((0, config_1.formatHour)(h, m))}`);
|
|
140
|
-
console.log(` ${DIM('Window resets:')} ${ACCENT(`~${(0, config_1.formatHour)(resetH, m)}`)}`);
|
|
141
|
-
console.log(` ${DIM('Platform:')} ${ACCENT((0, scheduler_1.getPlatformName)())}`);
|
|
142
|
-
console.log(` ${DIM('Boot-recovery:')} ${ACCENT('enabled')}`);
|
|
143
|
-
console.log('');
|
|
144
|
-
const { confirm } = await inquirer_1.default.prompt([{
|
|
145
|
-
type: 'confirm',
|
|
146
|
-
name: 'confirm',
|
|
147
|
-
message: 'Set up this schedule?',
|
|
148
|
-
default: true,
|
|
149
|
-
}]);
|
|
150
|
-
if (!confirm) {
|
|
151
|
-
console.log(DIM('\n Setup cancelled.\n'));
|
|
152
|
-
return;
|
|
153
|
-
}
|
|
154
|
-
// Install
|
|
155
|
-
const installSpinner = (0, ora_1.default)({
|
|
156
|
-
text: `Installing schedule (${(0, scheduler_1.getPlatformName)()})...`,
|
|
157
|
-
color: 'magenta',
|
|
158
|
-
}).start();
|
|
159
|
-
try {
|
|
160
|
-
(0, config_1.ensureConfigDir)();
|
|
161
|
-
const runtime = (0, runtime_1.resolveRuntimePaths)();
|
|
162
|
-
(0, scheduler_1.installSchedule)({ hour: h, minute: m, runtime });
|
|
163
|
-
const config = (0, config_1.createDefaultConfig)(time, timezone, runtime);
|
|
164
|
-
(0, config_1.writeConfig)(config);
|
|
165
|
-
installSpinner.succeed('Schedule installed with boot-recovery');
|
|
166
|
-
// Animate the setup complete visualization
|
|
167
|
-
await (0, ui_1.animateSetupComplete)(config);
|
|
168
|
-
}
|
|
169
|
-
catch (err) {
|
|
170
|
-
installSpinner.fail(`Installation failed: ${err.message}`);
|
|
171
|
-
}
|
|
188
|
+
const plan = buildSetupInstallPlan(startMins, exhaustMins, timezone);
|
|
189
|
+
await confirmAndInstallSchedule(plan);
|
|
172
190
|
}
|
|
173
191
|
//# sourceMappingURL=setup.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"setup.js","sourceRoot":"","sources":["../../src/commands/setup.ts"],"names":[],"mappings":";;;;;
|
|
1
|
+
{"version":3,"file":"setup.js","sourceRoot":"","sources":["../../src/commands/setup.ts"],"names":[],"mappings":";;;;;AA0DA,4DAqBC;AAGD,0DA0BC;AAED,sDAmBC;AAoBD,8DAuCC;AAED,oCA6EC;AA3QD,wDAAgC;AAChC,kDAA0B;AAC1B,8CAAsB;AACtB,sCAQmB;AACnB,sCAAqE;AACrE,4CAAiE;AACjE,8BASe;AACf,wCAAoE;AAEpE,MAAM,MAAM,GAAG,eAAK,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC;AACpC,MAAM,GAAG,GAAG,eAAK,CAAC,IAAI,CAAC;AA8BvB,+DAA+D;AAC/D,SAAgB,wBAAwB;IACtC,MAAM,OAAO,GAAG,EAAE,CAAC;IACnB,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,EAAE,EAAE,CAAC,EAAE,EAAE,CAAC;QAC5B,KAAK,MAAM,CAAC,IAAI,CAAC,CAAC,EAAE,EAAE,CAAC,EAAE,CAAC;YACxB,MAAM,MAAM,GAAG,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC;YACrC,MAAM,GAAG,GAAG,CAAC,GAAG,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,IAAI,CAAC,8DAA8D,CAAC,CAAC,CAAC;IACxF,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;IAEhB,MAAM,EAAE,SAAS,EAAE,GAAG,MAAM,kBAAQ,CAAC,MAAM,CAAC,CAAC;YAC3C,IAAI,EAAE,MAAM;YACZ,IAAI,EAAE,WAAW;YACjB,OAAO,EAAE,6DAA6D;YACtE,OAAO,EAAE,wBAAwB,EAAE;YACnC,OAAO,EAAE,CAAC,GAAG,EAAE;YACf,QAAQ,EAAE,EAAE;SACb,CAAC,CAAC,CAAC;IAEJ,MAAM,EAAE,WAAW,EAAE,GAAG,MAAM,kBAAQ,CAAC,MAAM,CAAC,CAAC;YAC7C,IAAI,EAAE,MAAM;YACZ,IAAI,EAAE,aAAa;YACnB,OAAO,EAAE,wEAAwE;YACjF,OAAO,EAAE;gBACP,EAAE,IAAI,EAAE,UAAU,EAAE,KAAK,EAAE,EAAE,EAAE;gBAC/B,EAAE,IAAI,EAAE,WAAW,EAAE,KAAK,EAAE,GAAG,EAAE;gBACjC,EAAE,IAAI,EAAE,WAAW,EAAE,KAAK,EAAE,GAAG,EAAE;gBACjC,EAAE,IAAI,EAAE,WAAW,EAAE,KAAK,EAAE,GAAG,EAAE;gBACjC,EAAE,IAAI,EAAE,mCAAmC,EAAE,KAAK,EAAE,GAAG,EAAE;aAC1D;YACD,OAAO,EAAE,GAAG;SACb,CAAC,CAAC,CAAC;IAEJ,MAAM,IAAI,GAAG,qBAAqB,CAAC,SAAS,EAAE,WAAW,EAAE,QAAQ,CAAC,CAAC;IAErE,MAAM,yBAAyB,CAAC,IAAI,CAAC,CAAC;AACxC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"update.d.ts","sourceRoot":"","sources":["../../src/commands/update.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"update.d.ts","sourceRoot":"","sources":["../../src/commands/update.ts"],"names":[],"mappings":"AAyDA,wBAAsB,aAAa,IAAI,OAAO,CAAC,IAAI,CAAC,CAkDnD"}
|