@ccdevkit/ccaudit 0.6.0 → 0.6.2

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.
Files changed (2) hide show
  1. package/README.md +66 -7
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -78,26 +78,55 @@ Review the code for:
78
78
  - **Check**: Single verification (one `.sh` or `.md` file)
79
79
  - **Audit**: Collection of checks (directory with `audit.yaml`)
80
80
 
81
- Checks run sequentially and stop at first failure.
81
+ Checks run in parallel by default, respecting any declared dependencies.
82
82
 
83
83
  ## audit.yaml
84
84
 
85
- The `audit.yaml` file can optionally specify which checks to run:
85
+ The `audit.yaml` file configures the audit:
86
86
 
87
87
  ```yaml
88
+ cwd: ../.. # Working directory for checks (relative to audit.yaml)
88
89
  checks:
89
90
  - ../shared/* # All checks from shared/ directory
90
91
  - ../other-audit # All checks from another audit (recursively)
91
92
  - ./check-custom.sh # Specific check file
93
+ - file: ./check-slow.sh # Object syntax with dependencies
94
+ dependencies:
95
+ - ./check-setup.sh # Must complete before check-slow.sh runs
92
96
  ```
93
97
 
94
- Paths are relative to the audit directory. Wildcards (`*`, `?`, `[...]`) are supported.
98
+ ### Fields
99
+
100
+ | Field | Description |
101
+ |-------|-------------|
102
+ | `cwd` | Working directory for all checks (absolute or relative to audit.yaml). Default: where ccaudit was invoked. |
103
+ | `checks` | List of checks to run. Supports strings or objects with `file` and `dependencies`. |
104
+
105
+ ### Check Discovery
95
106
 
96
- **Check discovery behavior:**
97
107
  - **No `checks:` field**: All `.sh` and `.md` files in the audit directory are loaded (default)
98
108
  - **`checks:` with items**: Only the specified items are loaded (exclusive mode)
99
109
  - **`checks: []` (empty)**: No checks are loaded (audit runs nothing)
100
110
 
111
+ Paths are relative to the audit directory. Wildcards (`*`, `?`, `[...]`) are supported.
112
+
113
+ ### Dependencies
114
+
115
+ Checks can declare dependencies to control execution order:
116
+
117
+ ```yaml
118
+ checks:
119
+ - ./setup.sh
120
+ - file: ./test.sh
121
+ dependencies: ./setup.sh # Single dependency (string)
122
+ - file: ./integration.sh
123
+ dependencies: # Multiple dependencies (array)
124
+ - ./setup.sh
125
+ - ./test.sh
126
+ ```
127
+
128
+ Checks with satisfied dependencies run in parallel. Dependent checks wait for their prerequisites to complete.
129
+
101
130
  ## Configuration
102
131
 
103
132
  Settings file: `.ccaudit/settings.json` (project) or `~/.ccaudit/settings.json` (global)
@@ -105,7 +134,8 @@ Settings file: `.ccaudit/settings.json` (project) or `~/.ccaudit/settings.json`
105
134
  ```json
106
135
  {
107
136
  "claudeCommand": "claude --local",
108
- "claudeCommandSummary": "~/.local/bin/claude"
137
+ "claudeCommandSummary": "~/.local/bin/claude",
138
+ "maxRunners": 4
109
139
  }
110
140
  ```
111
141
 
@@ -113,6 +143,7 @@ Settings file: `.ccaudit/settings.json` (project) or `~/.ccaudit/settings.json`
113
143
  |---------|---------|-------------|
114
144
  | `claudeCommand` | `claude` | Command to invoke Claude CLI (supports arguments) |
115
145
  | `claudeCommandSummary` | `claude` | Command for internal summary operations (MCP haiku calls) |
146
+ | `maxRunners` | `0` | Maximum parallel check runners. `0` = unlimited parallelism. |
116
147
 
117
148
  ## CLI Reference
118
149
 
@@ -123,6 +154,24 @@ ccaudit run <audit-name> Execute an audit
123
154
 
124
155
  ccaudit list List available audits
125
156
  -v, --verbose Enable debug output
157
+
158
+ ccaudit completion <shell> Generate shell completion script
159
+ Shells: bash, zsh, fish, powershell
160
+ ```
161
+
162
+ ## Shell Completion
163
+
164
+ Tab completion is automatically installed when using npm. For manual setup:
165
+
166
+ ```bash
167
+ # Bash
168
+ ccaudit completion bash > /etc/bash_completion.d/ccaudit
169
+
170
+ # Zsh
171
+ ccaudit completion zsh > "${fpath[1]}/_ccaudit"
172
+
173
+ # Fish
174
+ ccaudit completion fish > ~/.config/fish/completions/ccaudit.fish
126
175
  ```
127
176
 
128
177
  ## Output Modes
@@ -163,6 +212,7 @@ Shell:
163
212
  #!/bin/bash
164
213
  # ---
165
214
  # name: check-name
215
+ # requires: transcript # Optional: skip if no transcript available
166
216
  # ---
167
217
  ```
168
218
 
@@ -170,10 +220,19 @@ Markdown:
170
220
  ```markdown
171
221
  ---
172
222
  name: check-name
173
- model: haiku # Optional
223
+ model: haiku # Optional: haiku (default), sonnet, opus
224
+ requires: transcript # Optional: skip if no transcript available
174
225
  ---
175
226
  ```
176
227
 
228
+ ### Frontmatter Fields
229
+
230
+ | Field | Applies to | Description |
231
+ |-------|-----------|-------------|
232
+ | `name` | Both | Check name (required) |
233
+ | `model` | Agent only | AI model to use: `haiku` (default), `sonnet`, `opus` |
234
+ | `requires` | Both | Requirements that must be met. Currently supports `transcript` to skip when running standalone (not as a hook). |
235
+
177
236
  ## Agent Check Behavior
178
237
 
179
238
  Agent checks run in read-only mode. They can use `Read`, `Glob`, `Grep`, and `Bash` (for read operations only).
@@ -206,5 +265,5 @@ Agent checks return structured JSON:
206
265
 
207
266
  ## Exit Codes
208
267
 
209
- - `0`: All checks passed
268
+ - `0`: All checks passed (skipped checks don't affect exit code)
210
269
  - `1`: At least one check failed or error occurred
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ccdevkit/ccaudit",
3
- "version": "0.6.0",
3
+ "version": "0.6.2",
4
4
  "description": "Audit tool for Claude Code projects - runs compliance checks on code and agent actions",
5
5
  "bin": {
6
6
  "ccaudit": "bin/ccaudit"