-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Current State
Arguments are parsed manually via os.Args iteration in main.go. While functional, this approach has limitations:
- Hard to extend with new flags
- No auto-generated help text
- Duplicated parsing logic
- No built-in validation
Options to Consider
Option 1: Keep manual parsing (current)
Pros: Zero dependencies, full control
Cons: Maintenance burden grows with features
Option 2: Use github.com/spf13/cobra
Pros: Industry standard, subcommands, auto-completion, auto-help
Cons: Heavy dependency (~15K lines)
Option 3: Use github.com/urfave/cli/v2
Pros: Lighter than cobra, good features
Cons: Another dependency
Option 4: Use stdlib flag package
Pros: No external deps, standard Go
Cons: Limited features, no subcommands
Recommendation
Given the project's philosophy of minimal dependencies, Option 4 (stdlib flag) or staying with manual parsing may be preferred.
However, if features grow significantly, cobra would be worth the trade-off.
Decision Needed
- Evaluate if current feature set justifies a CLI library
- If yes, choose library
- If no, document the decision in CLAUDE.md
Labels
enhancement, discussion
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels