@lahat-group/cli 1.1.8 → 2.0.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/dist/index.js +57 -12168
- package/package.json +1 -2
- package/skill/SKILL.md +9 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lahat-group/cli",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "2.0.0",
|
|
4
4
|
"description": "CLI + Claude Skill to build, validate, price, and save wardrobe designs.",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"type": "module",
|
|
@@ -30,7 +30,6 @@
|
|
|
30
30
|
"test": "vitest run"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
33
|
-
"@wardrobe/shared": "*",
|
|
34
33
|
"commander": "^12.0.0",
|
|
35
34
|
"ky": "^1.14.3",
|
|
36
35
|
"tsup": "^8.0.0",
|
package/skill/SKILL.md
CHANGED
|
@@ -12,8 +12,13 @@ agent loop is: **init → edit → validate → price → plan → apply**.
|
|
|
12
12
|
## Prerequisites
|
|
13
13
|
|
|
14
14
|
- Install the CLI: `npm install -g @lahat-group/cli` (or run ad-hoc via `npx @lahat-group/cli <verb>`).
|
|
15
|
-
It ships as a self-contained binary — no build step, no extra dependencies.
|
|
16
|
-
|
|
15
|
+
It ships as a self-contained binary — no build step, no extra dependencies. It holds
|
|
16
|
+
no domain logic of its own; the rules live in the API.
|
|
17
|
+
- **Authenticate first — every verb needs it.** The CLI is a thin HTTP client: `init`,
|
|
18
|
+
`validate` and `describe` are served by the API just as `price` and `apply` are, so
|
|
19
|
+
none of them work offline. `Not authenticated. Run \`wardrobe login\` first.` means
|
|
20
|
+
exactly that.
|
|
21
|
+
- `wardrobe login` runs the OAuth device flow — it prints a
|
|
17
22
|
user code, opens `/activate` in the browser, and stores a scoped agent key at
|
|
18
23
|
`~/.config/wardrobe/config.json` (chmod 600). Confirm with `wardrobe whoami`.
|
|
19
24
|
- The CLI targets the **production** API by default. Set `WARDROBE_API_URL` to override
|
|
@@ -26,7 +31,8 @@ agent loop is: **init → edit → validate → price → plan → apply**.
|
|
|
26
31
|
emits a fresh, valid `WardrobeConfig` (full-width, split into optimal columns).
|
|
27
32
|
2. **edit** — modify `wardrobe.json` directly (see shape below).
|
|
28
33
|
3. **validate** — `wardrobe validate wardrobe.json` (or `-` for stdin). Runs the
|
|
29
|
-
**
|
|
34
|
+
**live** constraint pipeline server-side — the same rules `wardrobe price` enforces,
|
|
35
|
+
so a config `validate` approves can never be one `price` rejects.
|
|
30
36
|
Exit 0 = valid; exit 1 + structured errors otherwise. Do this after every edit.
|
|
31
37
|
4. **price** — `wardrobe price wardrobe.json` → authoritative total in **NIS** from
|
|
32
38
|
the API's unified area×rate engine.
|