Conversation
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 2 potential issues.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 35f45b4. Configure here.
| } | ||
|
|
||
| func Generate(opts Options) error { | ||
| fmt.Printf("%+v\n", opts) |
There was a problem hiding this comment.
Debug print statement left in production code
Medium Severity
Generate() contains a fmt.Printf("%+v\n", opts) debug statement that prints the full options struct to stdout. Every invocation of go generate will emit this noise to the terminal. This looks like a leftover from development/debugging that was unintentionally committed.
Reviewed by Cursor Bugbot for commit 35f45b4. Configure here.
|
|
||
| func GenerateComment() string { | ||
| return fmt.Sprintf("Code generated by enumify v%s. DO NOT EDIT.", Version()) | ||
| } |
There was a problem hiding this comment.
Generated comment missing Go-convention // prefix
Medium Severity
GenerateComment() returns "Code generated by enumify v… DO NOT EDIT." without the // prefix. The Go specification requires generated files to contain a line matching ^// Code generated .* DO NOT EDIT\.$. The test's own documentation quotes this pattern, but the test regex omits the // prefix, so the test passes despite the output not conforming to Go convention. Generated files won't be recognized as such by Go tools.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit 35f45b4. Configure here.


Scope of changes
Adds a CLI for code generation.
Estimated PR Size:
Acceptance criteria
This PR will be merged without review.
Author checklist
Note
Medium Risk
Introduces a new
cmd/enumifyentrypoint and new generation APIs, which may affectgo generateworkflows and downstream usage, but the implementation is mostly wiring/scaffolding with minimal business logic so far.Overview
Adds a real
enumifyCLI intended forgo generate, with flag-driven options to enable/disable specific generated outputs and a-versionmode plus custom usage text.Introduces an
enumify.Optionsstruct and new library entrypoints (Generate,GenerateTests, andGenerateComment) along with a semver-basedVersion()implementation; adds a small test to ensure the generated-code header matches Go’s requiredDO NOT EDITpattern and pulls ingo.rtnl.ai/xfor semver support.Reviewed by Cursor Bugbot for commit 35f45b4. Configure here.