contribute-now 0.8.0-dev.7eaa951 → 0.8.0-pr.6c582ea

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 (3) hide show
  1. package/README.md +35 -0
  2. package/dist/cli.js +1183 -455
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -305,6 +305,41 @@ cn validate "added stuff" # exit 1
305
305
 
306
306
  ---
307
307
 
308
+ ### `cn label`
309
+
310
+ Apply existing labels to issues and pull requests, or get ranked label suggestions from content. All operations are non-interactive and automation-friendly.
311
+
312
+ ```bash
313
+ # Apply one or more labels to an issue
314
+ cn label add --issue 42 bug,enhancement
315
+
316
+ # Apply labels with spaces in their names (no quotes needed in most shells)
317
+ cn label add --issue 42 bug,good first issue
318
+
319
+ # Apply labels to a PR
320
+ cn label add --pr 7 enhancement,needs triage
321
+
322
+ # Get ranked label suggestions for an issue
323
+ cn label suggest --issue 42
324
+
325
+ # Get ranked label suggestions for a PR
326
+ cn label suggest --pr 7
327
+ ```
328
+
329
+ **Label source strategy:**
330
+ 1. Repository labels are fetched once and cached locally (`.git/contribute-now/labels.json`).
331
+ 2. If the repository labels are a 100% name-match against the [Clean Labels](https://github.com/wgtechlabs/clean-labels) dataset, Clean Labels (with canonical descriptions) are used as the source.
332
+ 3. Otherwise, repository-specific labels are used.
333
+ 4. The local cache is used by default — no repeated `gh` API calls.
334
+ 5. On label-not-found errors, the cache is automatically resynced and the operation is retried once.
335
+
336
+ **Label input format:**
337
+ - Commas are the separator between labels.
338
+ - Spaces are part of a label name (`good first issue` is one label, not three words).
339
+ - Unknown labels are reported with close-match suggestions.
340
+
341
+ ---
342
+
308
343
  ## AI Features
309
344
 
310
345
  All AI features are **optional** — every command has a manual fallback. Three providers are supported: **GitHub Copilot**, **Ollama Cloud**, and **OpenRouter**.