asdm-cli 0.1.3 → 0.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 +43 -10
- package/dist/index.mjs +751 -211
- package/package.json +11 -2
- package/registry/latest.json +6 -4
- package/registry/policy.yaml +1 -0
- package/registry/profiles/base/profile.yaml +1 -0
- package/registry/v0.1.4.json +253 -0
- package/registry/v0.2.0.json +255 -0
- package/registry/v0.3.0.json +255 -0
- package/schemas/config.schema.json +1 -1
- package/schemas/manifest.schema.json +1 -1
- package/schemas/profile.schema.json +5 -1
package/README.md
CHANGED
|
@@ -15,12 +15,13 @@
|
|
|
15
15
|
# 1. Install globally (or use npx for zero-install)
|
|
16
16
|
npm install -g asdm-cli
|
|
17
17
|
|
|
18
|
-
#
|
|
19
|
-
asdm init
|
|
18
|
+
# Project Setup (per repository)
|
|
19
|
+
asdm init # creates .asdm.json
|
|
20
|
+
asdm sync # installs to project-local provider dirs
|
|
20
21
|
|
|
21
|
-
#
|
|
22
|
-
asdm
|
|
23
|
-
asdm sync --global #
|
|
22
|
+
# Machine Setup (no project needed)
|
|
23
|
+
asdm init --global # creates ~/.config/asdm/config.json
|
|
24
|
+
asdm sync --global # installs to global provider config dirs
|
|
24
25
|
```
|
|
25
26
|
|
|
26
27
|
That's it. ASDM will download your team's canonical AI assistant configurations and emit them into the correct locations for every provider your project uses — OpenCode, Claude Code, and GitHub Copilot — all from a single command.
|
|
@@ -98,13 +99,15 @@ asdm init fullstack-engineer # specify profile pos
|
|
|
98
99
|
asdm init --profile data-analytics --registry github://acme/asdm-registry
|
|
99
100
|
asdm init --force # overwrite existing config
|
|
100
101
|
asdm init --gitignore # also update .gitignore
|
|
102
|
+
asdm init --global # write to ~/.config/asdm/config.json
|
|
101
103
|
```
|
|
102
104
|
|
|
103
105
|
| Option | Description |
|
|
104
106
|
|--------|-------------|
|
|
105
107
|
| `--registry <url>` | Registry URL in `github://org/repo` format |
|
|
106
|
-
| `--force` | Overwrite existing
|
|
107
|
-
| `--gitignore` | Add ASDM output dirs to `.gitignore` automatically |
|
|
108
|
+
| `--force` | Overwrite existing config |
|
|
109
|
+
| `--gitignore` | Add ASDM output dirs to `.gitignore` automatically (local only) |
|
|
110
|
+
| `--global` | Write to `~/.config/asdm/config.json` instead of `.asdm.json` |
|
|
108
111
|
|
|
109
112
|
---
|
|
110
113
|
|
|
@@ -262,6 +265,8 @@ asdm clean # remove all managed files + lockfile
|
|
|
262
265
|
asdm clean --target opencode # only clean OpenCode files
|
|
263
266
|
asdm clean --target claude-code # only clean Claude Code files
|
|
264
267
|
asdm clean --dry-run # preview what would be removed
|
|
268
|
+
asdm clean --global # remove all globally managed files
|
|
269
|
+
asdm clean --global --target opencode # only clean OpenCode global files
|
|
265
270
|
```
|
|
266
271
|
|
|
267
272
|
When run interactively (TTY), you will be prompted to confirm before any files are deleted. After cleaning, a summary shows how many files were removed and how much disk space was freed.
|
|
@@ -270,6 +275,7 @@ When run interactively (TTY), you will be prompted to confirm before any files a
|
|
|
270
275
|
|--------|-------------|
|
|
271
276
|
| `--dry-run` | Preview what would be removed without deleting |
|
|
272
277
|
| `--target <provider>` | Only clean files for a specific provider |
|
|
278
|
+
| `--global` | Clean globally managed files (reads `~/.config/asdm/global-lock.json`) |
|
|
273
279
|
|
|
274
280
|
---
|
|
275
281
|
|
|
@@ -356,6 +362,21 @@ Created automatically by `asdm use <profile>`. Never edit this manually.
|
|
|
356
362
|
}
|
|
357
363
|
```
|
|
358
364
|
|
|
365
|
+
### `~/.config/asdm/config.json` — Global config
|
|
366
|
+
|
|
367
|
+
Created by `asdm init --global`. Stores registry, profile, and provider settings for machine-wide installation. Uses the same schema as `.asdm.json`.
|
|
368
|
+
|
|
369
|
+
```json
|
|
370
|
+
{
|
|
371
|
+
"$schema": "https://asdm.dev/schemas/config.schema.json",
|
|
372
|
+
"registry": "github://lennonalvesdias/asdm",
|
|
373
|
+
"profile": "base",
|
|
374
|
+
"providers": ["opencode"]
|
|
375
|
+
}
|
|
376
|
+
```
|
|
377
|
+
|
|
378
|
+
> **Note:** This file is the fallback config source when running `asdm sync --global` or `asdm verify --global` outside of a project directory.
|
|
379
|
+
|
|
359
380
|
### `.asdm-lock.json` — Lockfile (committed to git)
|
|
360
381
|
|
|
361
382
|
Generated by `asdm sync`. Records the exact SHA-256 of every emitted file and the manifest version. Enables:
|
|
@@ -566,9 +587,11 @@ ASDM emits files in each provider's native format. You never write provider-spec
|
|
|
566
587
|
Use `asdm sync --global` to install agents, skills, and commands into the global config directories of each provider. This makes your AI assistant configuration available in **every project** without per-project setup.
|
|
567
588
|
|
|
568
589
|
```bash
|
|
569
|
-
|
|
570
|
-
asdm
|
|
571
|
-
asdm
|
|
590
|
+
# First-time machine setup (no project needed):
|
|
591
|
+
asdm init --global # creates ~/.config/asdm/config.json
|
|
592
|
+
asdm sync --global # installs to global provider dirs
|
|
593
|
+
asdm verify --global # verify global installation
|
|
594
|
+
asdm clean --global # remove global installation (when needed)
|
|
572
595
|
```
|
|
573
596
|
|
|
574
597
|
### Global config directories
|
|
@@ -592,6 +615,16 @@ Project-root files (`AGENTS.md`, `CLAUDE.md`) are skipped in global mode — the
|
|
|
592
615
|
|
|
593
616
|
The global lockfile is stored at `~/.config/asdm/global-lock.json`, separate from any project's `.asdm-lock.json`.
|
|
594
617
|
|
|
618
|
+
### Config resolution
|
|
619
|
+
|
|
620
|
+
The `--global` flag controls **where files are written** (global provider dirs vs project-local). The config source for `sync` and `verify` with `--global` is resolved in this order:
|
|
621
|
+
|
|
622
|
+
1. Local `.asdm.json` in the current directory (if present)
|
|
623
|
+
2. `~/.config/asdm/config.json` (fallback — created by `asdm init --global`)
|
|
624
|
+
3. Error: *"No config found. Run `asdm init` (project) or `asdm init --global` (machine-wide setup)."*
|
|
625
|
+
|
|
626
|
+
This means you can run `asdm sync --global` from any directory — it will use the project config if you're inside a project, or fall back to your global config automatically.
|
|
627
|
+
|
|
595
628
|
---
|
|
596
629
|
|
|
597
630
|
## Integrity & Governance
|