@roblourens/dap-cli 0.1.0 → 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 +37 -8
- package/dist/index.js +1779 -183
- package/dist/index.js.map +1 -1
- package/package.json +10 -3
package/README.md
CHANGED
|
@@ -2,11 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Give your agent debugging skills!
|
|
4
4
|
|
|
5
|
-
A command-line debugger built for AI agents. Drive any [Debug Adapter Protocol](https://microsoft.github.io/debug-adapter-protocol/) target — Node.js, Python, Chrome, custom adapters — from shell commands, with stable JSON output and `.vscode/launch.json` support.
|
|
6
|
-
|
|
7
|
-
```bash
|
|
8
|
-
npm install -g dap-cli
|
|
9
|
-
```
|
|
5
|
+
A command-line debugger built for AI agents. Drive any [Debug Adapter Protocol](https://microsoft.github.io/debug-adapter-protocol/) target — Node.js, Python, Go, Rust, Chrome, custom adapters — from shell commands, with stable JSON output and `.vscode/launch.json` support.
|
|
10
6
|
|
|
11
7
|
## Why
|
|
12
8
|
|
|
@@ -19,15 +15,48 @@ Agents already know how to run shell commands. They don't know how to drive an I
|
|
|
19
15
|
## Install the CLI
|
|
20
16
|
|
|
21
17
|
```bash
|
|
22
|
-
npm install -g dap-cli
|
|
18
|
+
npm install -g @roblourens/dap-cli
|
|
23
19
|
dap-cli --version
|
|
24
20
|
```
|
|
25
21
|
|
|
26
|
-
|
|
22
|
+
(Or use `npx @roblourens/dap-cli ...` for one-off invocations — the cache below is shared across both install paths.)
|
|
23
|
+
|
|
24
|
+
**First launch:** when an agent first runs a `launch` / `attach`, dap-cli prompts before downloading the relevant adapter binary:
|
|
25
|
+
|
|
26
|
+
```text
|
|
27
|
+
Install vscode-js-debug 1.117.0 into ~/.dap-cli/adapters/js-debug/ (~10MB)? [y/N]
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
Answer `y`. The adapter is downloaded into `~/.dap-cli/adapters/` once and reused for every subsequent session. Only the adapter you actually use is downloaded — if you only debug Python, you never download js-debug, delve, or CodeLLDB.
|
|
31
|
+
|
|
32
|
+
Built-in adapters are `js-debug` for JavaScript/browser targets, `debugpy` for Python, `delve` for Go, and `codelldb` (CodeLLDB) for explicit compiled Rust executables.
|
|
33
|
+
|
|
34
|
+
**Non-interactive callers (agents, CI, scripts):** pre-consent so the prompt does not block:
|
|
35
|
+
|
|
36
|
+
```bash
|
|
37
|
+
dap-cli launch --yes --config "Launch App" # per-invocation flag
|
|
38
|
+
DAP_CLI_ASSUME_YES=1 dap-cli launch ... # equivalent env var
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
When stdin is not a TTY and neither `--yes` nor `DAP_CLI_ASSUME_YES=1` is set, dap-cli fails fast with `provision_consent_required` rather than hanging on a prompt nobody can answer.
|
|
42
|
+
|
|
43
|
+
**Pre-warm the cache (optional):** for sealed CI images or fresh dev machines, install all four built-in adapters up front:
|
|
44
|
+
|
|
45
|
+
```bash
|
|
46
|
+
dap-cli setup-adapters --yes
|
|
47
|
+
dap-cli setup-adapters --adapter js-debug --yes # or one at a time
|
|
48
|
+
dap-cli setup-adapters --adapter codelldb --yes # Rust / CodeLLDB only
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
**Custom cache location:** set `DAP_CLI_ADAPTERS_DIR=/path/to/cache` to override the default `~/.dap-cli/adapters/` (useful for shared CI caches or air-gapped pre-staged installs).
|
|
52
|
+
|
|
53
|
+
See [docs/adapter-setup.md](docs/adapter-setup.md) for the full reference — pinned versions, cache layout, concurrency model, proxy support, the `provision_*` error catalogue, troubleshooting, and custom adapter configuration.
|
|
54
|
+
|
|
55
|
+
> **Repo contributors:** `npm run setup-adapters` still works as a dev wrapper around `dap-cli setup-adapters`; end users should use the CLI subcommand directly.
|
|
27
56
|
|
|
28
57
|
## Install the agent skill
|
|
29
58
|
|
|
30
|
-
The repo includes an [Open Plugins](https://open-plugins.com/) plugin. The [SKILL.md](dap-cli/skills/dap-cli/SKILL.md)
|
|
59
|
+
The repo includes an [Open Plugins](https://open-plugins.com/) plugin. The [SKILL.md](dap-cli/skills/dap-cli/SKILL.md) teaches your agent how to use the CLI — common commands, the polling loop, breakpoint verification, and language-specific gotchas for `js-debug`, `debugpy`, Delve, and CodeLLDB.
|
|
31
60
|
|
|
32
61
|
**VS Code (Copilot Chat agent mode):**
|
|
33
62
|
|