@ciandt-flow/cli 1.0.3 → 1.0.4
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 +76 -237
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -2,336 +2,175 @@
|
|
|
2
2
|
|
|
3
3
|
TUI for browsing and installing Claude Code plugins from the Flow ecosystem.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## Installation
|
|
6
6
|
|
|
7
7
|
```bash
|
|
8
|
-
|
|
9
|
-
cp .env.example .env
|
|
10
|
-
bun run dev
|
|
8
|
+
npm install -g @ciandt-flow/cli
|
|
11
9
|
```
|
|
12
10
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
## Development
|
|
11
|
+
## Quick Start
|
|
16
12
|
|
|
17
13
|
```bash
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
bun run lint # Lint check
|
|
21
|
-
bun run format # Format + lint fix
|
|
22
|
-
```
|
|
23
|
-
|
|
24
|
-
## CLI Commands
|
|
25
|
-
|
|
26
|
-
### `setup`
|
|
27
|
-
|
|
28
|
-
Setup and configuration commands.
|
|
29
|
-
|
|
30
|
-
#### `setup init`
|
|
31
|
-
|
|
32
|
-
Initialize Flow CLI configuration.
|
|
14
|
+
# Authenticate with your Flow credentials
|
|
15
|
+
flow auth login
|
|
33
16
|
|
|
34
|
-
|
|
35
|
-
|
|
17
|
+
# Launch the interactive plugin browser
|
|
18
|
+
flow
|
|
36
19
|
```
|
|
37
20
|
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
### `plugin`
|
|
41
|
-
|
|
42
|
-
Plugin management commands.
|
|
43
|
-
|
|
44
|
-
#### `plugin list`
|
|
45
|
-
|
|
46
|
-
List plugins.
|
|
21
|
+
## Commands
|
|
47
22
|
|
|
48
|
-
|
|
49
|
-
flow-plugins plugin list [options]
|
|
50
|
-
```
|
|
23
|
+
### `flow` (no arguments)
|
|
51
24
|
|
|
52
|
-
|
|
53
|
-
|---|---|
|
|
54
|
-
| `--available` | Show all plugins from catalog with install status |
|
|
55
|
-
| `--outdated` | Show installed plugins with updates available |
|
|
56
|
-
| `--json` | Output as JSON |
|
|
25
|
+
Launches the interactive TUI to browse and manage plugins.
|
|
57
26
|
|
|
58
|
-
|
|
59
|
-
# list installed plugins (default)
|
|
60
|
-
bun dev plugin list
|
|
61
|
-
|
|
62
|
-
# list all plugins from catalog
|
|
63
|
-
bun dev plugin list --available
|
|
27
|
+
---
|
|
64
28
|
|
|
65
|
-
|
|
66
|
-
bun dev plugin list --outdated
|
|
29
|
+
### `auth`
|
|
67
30
|
|
|
68
|
-
|
|
69
|
-
bun dev plugin list --json
|
|
70
|
-
bun dev plugin list --available --json
|
|
71
|
-
```
|
|
31
|
+
Authentication commands.
|
|
72
32
|
|
|
73
|
-
#### `
|
|
33
|
+
#### `auth login`
|
|
74
34
|
|
|
75
|
-
|
|
35
|
+
Authenticate and save credentials.
|
|
76
36
|
|
|
77
37
|
```bash
|
|
78
|
-
flow
|
|
38
|
+
flow auth login [options]
|
|
79
39
|
```
|
|
80
40
|
|
|
81
41
|
| Option | Description |
|
|
82
42
|
|---|---|
|
|
83
|
-
| `--
|
|
84
|
-
| `--
|
|
85
|
-
| `--
|
|
86
|
-
|
|
87
|
-
```bash
|
|
88
|
-
# install a single plugin
|
|
89
|
-
bun dev plugin install flow-adr-writer
|
|
90
|
-
|
|
91
|
-
# install multiple plugins
|
|
92
|
-
bun dev plugin install flow-adr-writer flow-prd-writer startup-pack-ai
|
|
93
|
-
|
|
94
|
-
# force reinstall
|
|
95
|
-
bun dev plugin install flow-adr-writer --force
|
|
96
|
-
|
|
97
|
-
# silent (JSON output)
|
|
98
|
-
bun dev plugin install flow-adr-writer --silent
|
|
99
|
-
```
|
|
100
|
-
|
|
101
|
-
#### `plugin uninstall <id>`
|
|
43
|
+
| `--client-id <id>` | Client ID |
|
|
44
|
+
| `--client-secret <secret>` | Client Secret |
|
|
45
|
+
| `--tenant <tenant>` | Tenant |
|
|
102
46
|
|
|
103
|
-
|
|
47
|
+
When called **without options**, enters interactive mode — prompts for each field in the terminal.
|
|
48
|
+
When called **with all three options**, runs non-interactively and saves credentials directly.
|
|
104
49
|
|
|
105
50
|
```bash
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
#### `plugin enable <id>`
|
|
110
|
-
|
|
111
|
-
Enable an installed plugin.
|
|
51
|
+
# interactive mode
|
|
52
|
+
flow auth login
|
|
112
53
|
|
|
113
|
-
|
|
114
|
-
|
|
54
|
+
# non-interactive mode
|
|
55
|
+
flow auth login --client-id <id> --client-secret <secret> --tenant <tenant>
|
|
115
56
|
```
|
|
116
57
|
|
|
117
|
-
#### `
|
|
58
|
+
#### `auth logout`
|
|
118
59
|
|
|
119
|
-
|
|
60
|
+
Remove saved credentials.
|
|
120
61
|
|
|
121
62
|
```bash
|
|
122
|
-
|
|
63
|
+
flow auth logout [--force]
|
|
123
64
|
```
|
|
124
65
|
|
|
125
|
-
#### `
|
|
126
|
-
|
|
127
|
-
Update plugins to the latest version. Omit the name to update all installed plugins.
|
|
128
|
-
|
|
129
|
-
```bash
|
|
130
|
-
flow-plugins plugin update [name] [options]
|
|
131
|
-
```
|
|
66
|
+
#### `auth status`
|
|
132
67
|
|
|
133
|
-
|
|
134
|
-
|---|---|
|
|
135
|
-
| `--force` | Force update even if already on latest version |
|
|
136
|
-
| `--dry-run` | Show what would be updated without making changes |
|
|
137
|
-
| `--verbose` | Display each step of the update process |
|
|
138
|
-
| `--silent` | Output in JSON only |
|
|
68
|
+
Show current authentication status.
|
|
139
69
|
|
|
140
70
|
```bash
|
|
141
|
-
|
|
142
|
-
bun dev plugin update flow-adr-writer
|
|
143
|
-
|
|
144
|
-
# force update
|
|
145
|
-
bun dev plugin update flow-adr-writer --force
|
|
146
|
-
|
|
147
|
-
# dry-run (preview only)
|
|
148
|
-
bun dev plugin update flow-adr-writer --dry-run
|
|
149
|
-
|
|
150
|
-
# verbose (detailed logs)
|
|
151
|
-
bun dev plugin update flow-adr-writer --verbose
|
|
152
|
-
|
|
153
|
-
# silent (JSON output)
|
|
154
|
-
bun dev plugin update flow-adr-writer --silent
|
|
155
|
-
|
|
156
|
-
# update all plugins
|
|
157
|
-
bun dev plugin update
|
|
158
|
-
|
|
159
|
-
# dry-run all
|
|
160
|
-
bun dev plugin update --dry-run
|
|
71
|
+
flow auth status
|
|
161
72
|
```
|
|
162
73
|
|
|
163
74
|
---
|
|
164
75
|
|
|
165
|
-
### `
|
|
76
|
+
### `plugin`
|
|
166
77
|
|
|
167
|
-
|
|
78
|
+
Plugin management commands.
|
|
168
79
|
|
|
169
|
-
#### `
|
|
80
|
+
#### `plugin list`
|
|
170
81
|
|
|
171
|
-
|
|
82
|
+
List plugins.
|
|
172
83
|
|
|
173
84
|
```bash
|
|
174
|
-
flow
|
|
85
|
+
flow plugin list [options]
|
|
175
86
|
```
|
|
176
87
|
|
|
177
88
|
| Option | Description |
|
|
178
89
|
|---|---|
|
|
179
|
-
| `--
|
|
180
|
-
| `--
|
|
181
|
-
| `--
|
|
182
|
-
|
|
183
|
-
When called **without options**, enters interactive mode — prompts for each field in the terminal. The tenant field is pre-filled if one is detected from the environment.
|
|
184
|
-
|
|
185
|
-
When called **with all three options**, runs non-interactively and saves credentials directly.
|
|
90
|
+
| `--available` | Show all plugins from catalog with install status |
|
|
91
|
+
| `--outdated` | Show installed plugins with updates available |
|
|
92
|
+
| `--json` | Output as JSON |
|
|
186
93
|
|
|
187
94
|
```bash
|
|
188
|
-
#
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
#
|
|
192
|
-
bun dev auth login --client-id aa --client-secret bbb --tenant cit-dev
|
|
95
|
+
flow plugin list # list installed plugins
|
|
96
|
+
flow plugin list --available # list all plugins from catalog
|
|
97
|
+
flow plugin list --outdated # list plugins with updates available
|
|
98
|
+
flow plugin list --json # output as JSON
|
|
193
99
|
```
|
|
194
100
|
|
|
195
|
-
#### `
|
|
101
|
+
#### `plugin install <name...>`
|
|
196
102
|
|
|
197
|
-
|
|
103
|
+
Install one or more plugins.
|
|
198
104
|
|
|
199
105
|
```bash
|
|
200
|
-
flow
|
|
106
|
+
flow plugin install <name...> [options]
|
|
201
107
|
```
|
|
202
108
|
|
|
203
109
|
| Option | Description |
|
|
204
110
|
|---|---|
|
|
205
|
-
| `--force` |
|
|
111
|
+
| `--force` | Reinstall even if already installed |
|
|
112
|
+
| `--verbose` | Display each installation step |
|
|
113
|
+
| `--silent` | Output as JSON only |
|
|
206
114
|
|
|
207
115
|
```bash
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
# skip confirmation
|
|
212
|
-
bun dev auth logout --force
|
|
116
|
+
flow plugin install flow-adr-writer
|
|
117
|
+
flow plugin install flow-adr-writer flow-prd-writer
|
|
118
|
+
flow plugin install flow-adr-writer --force
|
|
213
119
|
```
|
|
214
120
|
|
|
215
|
-
#### `
|
|
121
|
+
#### `plugin uninstall <id>`
|
|
216
122
|
|
|
217
|
-
|
|
123
|
+
Uninstall a plugin by ID.
|
|
218
124
|
|
|
219
125
|
```bash
|
|
220
|
-
|
|
126
|
+
flow plugin uninstall <id>
|
|
221
127
|
```
|
|
222
128
|
|
|
223
|
-
|
|
129
|
+
#### `plugin enable <id>` / `plugin disable <id>`
|
|
224
130
|
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
Run diagnostic checks.
|
|
131
|
+
Enable or disable an installed plugin.
|
|
228
132
|
|
|
229
133
|
```bash
|
|
230
|
-
|
|
134
|
+
flow plugin enable <id>
|
|
135
|
+
flow plugin disable <id>
|
|
231
136
|
```
|
|
232
137
|
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
The CLI uses a dual-mode logger that adapts to the execution context.
|
|
236
|
-
|
|
237
|
-
### TUI mode (interactive)
|
|
238
|
-
|
|
239
|
-
When running without arguments (`flow`), Ink owns stdout. All logs go to **stderr** and a **log file** at `~/.flow/logs/flowsetup.log`.
|
|
138
|
+
#### `plugin update [name]`
|
|
240
139
|
|
|
241
|
-
|
|
242
|
-
- Use the `DEBUG` env var to enable debug output:
|
|
140
|
+
Update plugins to the latest version. Omit the name to update all installed plugins.
|
|
243
141
|
|
|
244
142
|
```bash
|
|
245
|
-
|
|
246
|
-
DEBUG=flow:* bun run dev
|
|
247
|
-
|
|
248
|
-
# specific module only (others stay at warn+)
|
|
249
|
-
DEBUG=flow:installer bun run dev
|
|
143
|
+
flow plugin update [name] [options]
|
|
250
144
|
```
|
|
251
145
|
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
When running a subcommand (e.g. `flow plugin install`), the logger writes to **stdout** by default.
|
|
255
|
-
|
|
256
|
-
| Flag | Behavior |
|
|
146
|
+
| Option | Description |
|
|
257
147
|
|---|---|
|
|
258
|
-
|
|
|
259
|
-
| `--
|
|
260
|
-
| `--
|
|
148
|
+
| `--force` | Force update even if already on latest version |
|
|
149
|
+
| `--dry-run` | Preview what would be updated without making changes |
|
|
150
|
+
| `--verbose` | Display each update step |
|
|
151
|
+
| `--silent` | Output as JSON only |
|
|
261
152
|
|
|
262
153
|
```bash
|
|
263
|
-
flow plugin
|
|
264
|
-
flow plugin
|
|
265
|
-
flow plugin update
|
|
266
|
-
flow plugin update my-plugin --silent
|
|
154
|
+
flow plugin update flow-adr-writer
|
|
155
|
+
flow plugin update # update all
|
|
156
|
+
flow plugin update --dry-run # preview only
|
|
267
157
|
```
|
|
268
158
|
|
|
269
|
-
### Credential sanitization
|
|
270
|
-
|
|
271
|
-
Every log message is automatically sanitized before being written. The following patterns are masked:
|
|
272
|
-
|
|
273
|
-
- Bearer tokens
|
|
274
|
-
- JWT tokens (`eyJ...` three-segment format)
|
|
275
|
-
- Long base64 strings (>40 chars)
|
|
276
|
-
|
|
277
|
-
### Log file rotation
|
|
278
|
-
|
|
279
|
-
The log file at `~/.flow/logs/flowsetup.log` is truncated when it exceeds **5 MB** at startup.
|
|
280
|
-
|
|
281
159
|
---
|
|
282
160
|
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
This project uses [Changesets](https://github.com/changesets/changesets) for version management and automated releases.
|
|
286
|
-
|
|
287
|
-
### How it works
|
|
288
|
-
|
|
289
|
-
1. Developers add a **changeset** describing their changes before opening a PR
|
|
290
|
-
2. On merge to `main`, a GitHub Action detects pending changesets and opens a **"Version Packages"** PR
|
|
291
|
-
3. That PR bumps the version in `package.json`, updates `CHANGELOG.md`, and removes consumed changesets
|
|
292
|
-
4. Merging the Version Packages PR triggers an automated **npm publish** with provenance
|
|
293
|
-
|
|
294
|
-
The version is read at runtime from `package.json` — there is no hardcoded version constant to keep in sync.
|
|
295
|
-
|
|
296
|
-
### Adding a changeset
|
|
297
|
-
|
|
298
|
-
After making your changes and before opening a PR, run:
|
|
299
|
-
|
|
300
|
-
```bash
|
|
301
|
-
bunx changeset
|
|
302
|
-
```
|
|
303
|
-
|
|
304
|
-
You'll be prompted to:
|
|
305
|
-
- Select the semver bump type (`patch`, `minor`, or `major`)
|
|
306
|
-
- Write a summary of the change (this goes into the CHANGELOG)
|
|
307
|
-
|
|
308
|
-
This creates a markdown file in `.changeset/`. Commit it with your PR.
|
|
309
|
-
|
|
310
|
-
> **When to use each bump type:**
|
|
311
|
-
> - `patch` — bug fixes, docs, internal refactors
|
|
312
|
-
> - `minor` — new features, non-breaking additions
|
|
313
|
-
> - `major` — breaking changes
|
|
161
|
+
### `health`
|
|
314
162
|
|
|
315
|
-
|
|
163
|
+
Run diagnostic checks.
|
|
316
164
|
|
|
317
165
|
```bash
|
|
318
|
-
|
|
319
|
-
bun run version-packages # Apply pending changesets (bump version + CHANGELOG)
|
|
320
|
-
bun run release # Build + publish to npm
|
|
166
|
+
flow health
|
|
321
167
|
```
|
|
322
168
|
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
### CI/CD
|
|
169
|
+
---
|
|
326
170
|
|
|
327
|
-
|
|
328
|
-
|---|---|---|
|
|
329
|
-
| `ci.yml` | Pull requests to `main` | Runs lint, test, and build |
|
|
330
|
-
| `release.yml` | Push to `main` | Runs CI checks, then creates a Version Packages PR or publishes to npm |
|
|
171
|
+
## Versioning
|
|
331
172
|
|
|
332
|
-
|
|
333
|
-
- `GITHUB_TOKEN` — provided automatically by GitHub Actions
|
|
334
|
-
- `NPM_TOKEN` — npm access token with publish permissions
|
|
173
|
+
This project follows [Semantic Versioning](https://semver.org/). See [CHANGELOG.md](https://github.com/CI-T-HyperX/flow-plugins-cli/blob/main/CHANGELOG.md) for release history.
|
|
335
174
|
|
|
336
175
|
## License
|
|
337
176
|
|