codemax-pro 1.2.1 → 1.3.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 +50 -56
- package/index.js +277 -484
- package/lib.js +455 -0
- package/package.json +3 -2
package/README.md
CHANGED
|
@@ -1,88 +1,82 @@
|
|
|
1
1
|
# ⚡ codemax-pro
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
Configures **Claude Code CLI**, the **VS Code extension**, and the **Claude Desktop app** in a few seconds.
|
|
6
|
-
|
|
7
|
-
## 🚀 Quick start
|
|
3
|
+
Setup for **CodeMax** (`api.codemax.pro`) — configures **Claude Code CLI**, the **VS Code
|
|
4
|
+
extension**, and the **Claude Desktop app**.
|
|
8
5
|
|
|
9
6
|
```bash
|
|
10
7
|
npx codemax-pro
|
|
11
8
|
```
|
|
12
9
|
|
|
13
|
-
Or pass
|
|
10
|
+
Or pass the key directly:
|
|
14
11
|
|
|
15
12
|
```bash
|
|
16
13
|
npx codemax-pro sk-cp-your-key-here
|
|
17
14
|
```
|
|
18
15
|
|
|
19
|
-
Re-run it any time to update your key.
|
|
20
|
-
|
|
21
|
-
---
|
|
22
|
-
|
|
23
|
-
## 🛠️ What it configures
|
|
24
|
-
|
|
25
|
-
1. **Validates your API key** against `api.codemax.pro` before changing anything
|
|
26
|
-
2. **Claude Code CLI + VS Code extension** — `~/.claude/settings.json`
|
|
27
|
-
3. **Claude Desktop** — third-party inference, provider `gateway`
|
|
28
|
-
4. **Installs Claude Code CLI** if it is missing (`@anthropic-ai/claude-code`)
|
|
29
|
-
5. Clears stale settings left by older versions
|
|
30
|
-
|
|
31
16
|
---
|
|
32
17
|
|
|
33
|
-
##
|
|
34
|
-
|
|
35
|
-
The desktop app is not the CLI. It does not read `~/.claude/settings.json`, and setting
|
|
36
|
-
`ANTHROPIC_BASE_URL` as an environment variable has no effect on it — it is its own application and
|
|
37
|
-
talks to whichever inference endpoint it is configured with.
|
|
18
|
+
## Commands
|
|
38
19
|
|
|
39
|
-
|
|
40
|
-
`gateway` and pointed at `api.codemax.pro`. It writes to both places the app looks:
|
|
41
|
-
|
|
42
|
-
| Platform | Written to |
|
|
20
|
+
| | |
|
|
43
21
|
| --- | --- |
|
|
44
|
-
|
|
|
45
|
-
|
|
|
46
|
-
|
|
|
22
|
+
| `codemax-pro [key]` | Configure everything |
|
|
23
|
+
| `codemax-pro doctor` | Report what is actually configured, and what is fighting it |
|
|
24
|
+
| `codemax-pro reset` | Remove what this tool set, and nothing else |
|
|
47
25
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
26
|
+
| Flag | |
|
|
27
|
+
| --- | --- |
|
|
28
|
+
| `--yes` | Never prompt |
|
|
29
|
+
| `--only cli` / `--only desktop` | Configure one surface only |
|
|
52
30
|
|
|
53
|
-
|
|
54
|
-
> Its configuration is read **once, at launch**. Closing the window leaves the process running, so
|
|
55
|
-
> a reopened window keeps the old settings and it looks like setup did not work. Quit from the
|
|
56
|
-
> system tray (Windows) or the menu bar (macOS) first.
|
|
31
|
+
The key can also come from `CODEMAX_API_KEY`.
|
|
57
32
|
|
|
58
33
|
---
|
|
59
34
|
|
|
60
|
-
##
|
|
35
|
+
## `doctor`
|
|
61
36
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
37
|
+
Run this first when something isn't working. It only reads — it changes nothing.
|
|
38
|
+
|
|
39
|
+
```
|
|
40
|
+
Claude Code CLI
|
|
41
|
+
✓ endpoint https://api.codemax.pro
|
|
42
|
+
✓ key sk-cp-a1b2…9f3c
|
|
43
|
+
✓ default model settings present
|
|
44
|
+
✓ claude CLI installed 2.1.81
|
|
45
|
+
|
|
46
|
+
Claude Desktop
|
|
47
|
+
✓ policy gateway → https://api.codemax.pro
|
|
48
|
+
✓ auth x-api-key
|
|
49
|
+
✓ models 4 configured
|
|
50
|
+
|
|
51
|
+
Conflicts
|
|
52
|
+
✓ no environment variables competing with the settings file
|
|
53
|
+
|
|
54
|
+
Connection
|
|
55
|
+
✓ endpoint reachable, key accepted 412ms
|
|
56
|
+
```
|
|
68
57
|
|
|
69
|
-
|
|
70
|
-
|
|
58
|
+
It exists because the failures here are quiet ones. Each of these looks identical to "the setup
|
|
59
|
+
didn't work", and none of them produces an error:
|
|
60
|
+
|
|
61
|
+
- an environment variable that outranks the settings file
|
|
62
|
+
- a machine-wide policy that outranks the per-user one
|
|
63
|
+
- an app still running with the configuration it read at launch
|
|
64
|
+
- a key that was rotated
|
|
71
65
|
|
|
72
66
|
---
|
|
73
67
|
|
|
74
|
-
|
|
68
|
+
> ### ⚠️ Quit Claude Desktop fully, then reopen it
|
|
69
|
+
> It reads its configuration **once, at launch**. Closing the window leaves the process running, so
|
|
70
|
+
> a reopened window keeps the old settings — and it looks exactly like setup failed. Quit from the
|
|
71
|
+
> system tray (Windows) or menu bar (macOS).
|
|
75
72
|
|
|
76
|
-
|
|
77
|
-
overriding your user settings — on Windows, a policy under `HKLM\SOFTWARE\Policies\Claude` makes the
|
|
78
|
-
app ignore the per-user one entirely. The setup tool warns when it finds one.
|
|
73
|
+
---
|
|
79
74
|
|
|
80
|
-
|
|
81
|
-
credential may be from a rotated key.
|
|
75
|
+
## Safety
|
|
82
76
|
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
77
|
+
- Existing settings are backed up beside the original as `*.codemax-backup` before being changed.
|
|
78
|
+
- Files are written atomically — an interrupted run cannot leave a half-written settings file.
|
|
79
|
+
- `reset` removes only the keys this tool set; anything else in those files is left alone.
|
|
86
80
|
|
|
87
81
|
---
|
|
88
82
|
|