-
-
Notifications
You must be signed in to change notification settings - Fork 1
Coco Issues Create
coco issues create opens a new issue on the detected forge (GitHub, GitLab, Bitbucket, or Gitea). It can pre-fill the title and body from a coco review finding, turning a review violation into a tracked issue in one step.
# Create an issue with explicit title and body
coco issues create --title "Fix login timeout" --body "The session expires..."
# Draft an issue from a review finding (pipe review output)
coco review --json | coco issues create --from-review
# Interactive: review and edit before creating
coco issues create --title "Refactor auth module" -i
# Dry run: see what would be created without creating it
coco issues create --title "Add tests" --dry-run
# JSON output (prints title/body without creating)
coco issues create --title "Add tests" --json| Flag | Default | Description |
|---|---|---|
--title <string> |
— | Issue title (required unless --from-review provides one) |
--body <string> |
— | Issue body |
--from-review |
false |
Draft the issue from coco review --json findings piped on stdin |
-i, --interactive
|
false |
Review and optionally edit the issue before creating |
--dry-run |
false |
Print the generated title/body without creating the issue |
--json |
false |
Emit { title, body } as JSON on stdout |
The most common workflow chains coco review into coco issues create:
# Review staged changes, pipe findings to issue creation
coco review --json --staged | coco issues create --from-review -iWhen multiple findings exist and stdin is interactive, coco presents a picker sorted by severity (highest first). Otherwise the highest-severity finding is selected automatically.
The findingToIssue formatter maps a review finding into:
- Title: the finding's title prefixed with the file path
- Body: severity, file path, line context, the finding's description, and suggested fix
With -i / --interactive, coco shows the generated title and body, then offers:
- Create — submit as-is
-
Edit & create — open in
$EDITORfor modification (first line = title, blank line, then body) - Cancel — abort without creating
coco issues create detects the forge from the git remote and dispatches through the appropriate API:
-
GitHub / GHE:
gh issue create -
GitLab:
glab apiPOST - Bitbucket Cloud: REST API
- Gitea / Forgejo: REST API
The command checks authentication status before attempting creation and surfaces clear recovery hints when the forge CLI is unavailable or unauthenticated.
- Issue & PR Triage — listing and managing issues
- Multi-Forge Support — forge detection and host mapping
- Command Reference