| Age | Commit message (Collapse) | Author |
|
- Renamed binary from perc to gt throughout the project
- Refactored calculator.Parse to use registration pattern for parsing strategies
- Refactored rpn.handleOperator to use operator registry instead of switch statements
- Added panic recovery to REPL executor for better resilience
- Improved code organization with OperatorRegistry and strategy registration
All changes maintain full test compatibility and pass race detection tests.
|
|
- Error wrapping improvements across multiple files
- Thread-safe singleton initialization using sync.Once
- Proper error handling for file close operations
- Removed speculative complexity in history management
- Fixed operator interface design
Audit report: COMPLETE_AUDIT_REPORT.md
|
|
|
|
- Changed Operations.vars from *Variables to VariableStore interface
- Changed NewOperations to accept VariableStore interface
- Changed RPN.vars from *Variables to VariableStore interface
- Changed NewRPN to accept VariableStore interface
- Removed type assertions in main.go and repl.go
- Added FormatVariables to VariableStore interface
- All tests pass, build successful
|
|
- Bare expressions like '1 2 +' now work without 'calc' prefix
- Assignment format 'name value =' requires 'calc' subcommand prefix
|
|
- 21 test functions covering version, calc, rpn subcommands
- Tests for assignment, percentage calculations, error handling, repl mode
- Coverage: runCommand 91.7%, runRPN 100%, printUsage 100%
|
|
- Test version, calc, rpn subcommands
- Test percentage calculations
- Test error handling (missing expressions, division by zero, unknown tokens)
- Test assignment with variables
- Test printUsage function
- Achieve 76% coverage of cmd/perc package
|
|
- Add calc and rpn subcommands to main.go
- Support RPN expression evaluation via perc calc/rpn <expr>
- Support variable assignment format: 'name value = expr...'
- Fix assignment parsing to handle 'name value = expression' format
- All tests pass, go vet passes
|
|
- Add REPL mode with vi keybindings
- Add built-in commands (help, clear, quit/exit)
- Add mage repl target
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Amp-Thread-ID: https://ampcode.com/threads/T-e4f4a959-8cc6-4ac0-b6fb-2779867e8b2a
Co-authored-by: Amp <amp@ampcode.com>
|