Refactor CLI to use structured command definitions #8
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The current CLI implementation relies on manual index-based argument parsing in main.rs, which is fragile and difficult to extend. We need to migrate this to a structured command pattern (using clap) to ensure consistent argument validation, automatic help generation, and a maintainable codebase.
Goals:
Todo
Phase 1: Scaffolding & Infrastructure
🧪 Phase 2: Iterative Command Implementation (TDD Cycle)
For each command group below, the workflow will be: Write Test
\rightarrowImplement Parsing\rightarrowImplement Logic\rightarrowVerify.🎨 Phase 3: Refinement & Polishing
🏁 Phase 4: Finalization
3rd draft for cli structure:
Global flags:
@jakob:
@opencode:
@jakob:
@opencode