Molecules are composable workflow templates used by Gas Town (gt) for
defining multi-step processes like bootstrap, engineer-in-box, etc.
Changes:
- Add TypeMolecule constant to internal/types/types.go
- Add molecule to IsValid() switch case
- Add molecule and merge-request to validation/bead.go validTypes map
- Update help text in create.go, show.go, list.go
- Add test cases for molecule and merge-request types
Closes gt-qn4l
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Claude was using word-based priorities like "medium" instead of numeric
values (0-4 or P0-P4), causing bd create commands to fail in a loop.
Changes:
- Update bd prime output to clearly document priority format with example
- Add explicit note: NOT "high"/"medium"/"low"
- Improve error message to mention that words are not valid
Closes#517🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Extracted repeated priority and ID validation patterns from CLI commands
into reusable functions in internal/validation/bead.go.
Changes:
- Added ValidatePriority(): Combines parsing and error handling
- Added ValidateIDFormat(): Validates ID format and extracts prefix
- Added ValidatePrefix(): Validates prefix matching with database config
- Updated create.go and show.go to use new validation functions
- Simplified force flag logic to always call ValidatePrefix()
- Added comprehensive tests for all validation functions
- Added TODO comment for daemon mode validation enhancement
Results:
- Reduced code duplication by ~20 lines
- Centralized validation logic for easier maintenance
- Consistent error messages across all commands
- All tests passing
Fixes bd-g5p7
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Created internal/validation package for centralized validation logic
- Created cmd/bd/flags.go for shared flag registration
- Updated create and update commands to use shared logic
- Added support for 'P1' style priority to update command
- Added tests for validation logic
Amp-Thread-ID: https://ampcode.com/threads/T-c8d369a3-32f0-42a0-96d1-fd589e89bd6b
Co-authored-by: Amp <amp@ampcode.com>