feat: add centy issue <id> shortcut alias for get issue#52
Open
tupe12334 wants to merge 1 commit into
Open
Conversation
Implements issue #111 by adding a top-level `issue` command that acts as a direct alias for `get issue`. Users can now run: centy issue <uuid> centy issue <display-number> centy issue <id> --json centy issue <id> --global centy issue <id> --project <name> This mirrors the same behaviour as `centy get issue <id>` without requiring the `get` subcommand to be typed. - Add src/commands/issue.ts with full flag parity (--json, --global, --project) - Add src/commands/issue.spec.ts with 10 unit tests covering display number lookup, UUID lookup, JSON output, global search (UUID and display number), error handling, NotInitializedError, --project flag, and args shape validation - Regenerate oclif.manifest.json to register the new command Closes #111 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
issuecommand so users can runcenty issue <id>directly without typing thegetsubcommand (closes issue #111)get issue:--json,--global, and--projectNotInitializedError, and the--projectflagMotivation
Issue #111 requested a shorter way to retrieve a single issue. Previously users had to type
centy get issue <id>orcenty show issue <id>. The newcenty issue <id>shortcut removes the need for the intermediate subcommand entirely.Changes
src/commands/issue.ts- New command class delegating to the samedaemonGetItem/handleGlobalGethelpers used byget issuesrc/commands/issue.spec.ts- 10 vitest unit testsoclif.manifest.json- Regenerated to register the newissuecommandTest plan
centy issue <display-number>returns the correct issuecenty issue <uuid>returns the correct issuecenty issue <id> --jsonoutputs raw JSONcenty issue <id> --globalsearches across all tracked projectscenty issue <id> --project <name>resolves the specified project pathpnpm test src/commands/issue.spec.ts)centy issue --helpshows the command description and examples🤖 Generated with Claude Code