@mainwave/cli 0.5.0 → 0.6.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.
@@ -47,23 +47,38 @@ Use the adapter for the tool you are running inside — `claude-code`, `codex`,
47
47
  `copilot-cli`, `copilot-chat`, `cursor`, `claude-desktop`. Run `setup` with no
48
48
  adapter to see what the CLI detects on this machine.
49
49
 
50
+ Config always lands in the user's home directory; there is no repo-local option,
51
+ so nothing setup writes can end up committed.
52
+
50
53
  `--json` gives you one parseable document on stdout; narrative goes to stderr.
51
54
  `--yes` is required for a non-interactive write — without it the CLI refuses
52
55
  rather than showing a diff nobody confirms.
53
56
 
54
57
  Flags worth knowing, all optional:
55
58
 
56
- - `--scope local` writes repo config instead of user-level. Global is the
57
- default and is usually right; local is a deliberate choice the user makes.
58
59
  - `--use-case "<name>"` creates a use case by name, `--ucid <id|url>` binds an
59
60
  existing one, `--no-use-case` skips. Left alone, the CLI asks — which it
60
61
  cannot do without a terminal, so pass one of these.
61
- - `--opt-in prompts,tool-details,tool-content` turns on the sensitive-data
62
- captures, all off by default.
63
-
64
- **Ask before enabling any opt-in.** `prompts` sends the user's prompt text off
65
- the machine. That is the user's call every time, not a default you pick for
66
- them, and not something to enable because it makes the demo better.
62
+ - `--opt-in` selects content capture. The default is **everything on** — prompt
63
+ text, shell commands and file paths, tool result bodies — and it is never
64
+ prompted for. `--opt-in none` sends metadata only; a named list
65
+ (`--opt-in tool-details`) selects exactly those.
66
+ - `--no-markers` skips the ticket & PR marker hooks, which are installed by
67
+ default. They emit issue keys and PR numbers/urls only — no bodies, no diffs —
68
+ and they are the only source of the "Tickets filed" / "PRs created" counts.
69
+
70
+ **Tell the user what the default captures, before you run setup.** Prompt text
71
+ and tool result bodies leave the machine under the default. If they want less:
72
+
73
+ - **Claude Code:** `--opt-in none` still gives them every activity view —
74
+ sessions, cost, tool mix, tickets, PRs, per-person activity all work on
75
+ metadata alone.
76
+ - **Codex:** `--opt-in none` empties its tool views, because Codex reports tool
77
+ names, success and approvals only with tool logging on. Offer
78
+ `--opt-in tool-details` instead — no prompt text, no tool output, tool views
79
+ intact — and say which one you are running.
80
+
81
+ Never talk someone out of less capture because it makes a demo better.
67
82
 
68
83
  ## 3. Prove it works
69
84
 
@@ -75,9 +90,10 @@ This pushes a sample trace and waits for it to land, so it proves the network
75
90
  path and the key. It does **not** prove the tool itself is emitting — the tool
76
91
  has to run first, and most tools only read the new config at launch.
77
92
 
78
- So: tell the user to restart the tool, have them do some work in it, then run
79
- `verify --no-sample` to watch for the tool's own spans without the synthetic
80
- one. Report the link it prints.
93
+ So: **tell the user to restart the tool** — every session that was already open,
94
+ including the one you are running in, since the config is read at startup — have
95
+ them do some work in it, then run `verify --no-sample` to watch for the tool's
96
+ own spans without the synthetic one. Report the link it prints.
81
97
 
82
98
  ## When something is already there
83
99
 
@@ -101,9 +117,13 @@ rather than duplicating.
101
117
  what is needed, say so rather than reaching for the settings file.
102
118
  - **Never print an API key, a token, or the contents of `~/.mainwave/credentials.json`.**
103
119
  The CLI masks secrets in its own output; don't undo that by `cat`-ing files.
104
- - **Never enable a data opt-in without asking.**
105
- - **Never commit a settings file containing a key.** If `--scope local` wrote
106
- into the repo, check what is tracked before suggesting a commit.
120
+ - **Say what the default captures; honour a request for less.** If the user asks
121
+ for minimal capture, give it to them — `--opt-in none`, or `--opt-in
122
+ tool-details` for Codex once they know what `none` costs there. Don't negotiate.
123
+ - **Never commit a settings file containing a key.** Setup writes only to the
124
+ home directory, but an older CLI or a colleague may have left a repo-local
125
+ file — `doctor <adapter>` lists every layer, so check before suggesting a
126
+ commit.
107
127
  - Report what the CLI reported. Do not summarize a failure into a success — a
108
128
  `verify` that timed out is a timeout, not "set up successfully".
109
129