googleapis / googleapis/cloud-bigtable-cbt-cli
Clean up arg parsing
Open
priority: p3
type: cleanup
- Dominant language
- Go
- Stars
- 15
- Forks
- 42
- PR merge metrics
- No merged PRs in 30d
Description
Each `do*()` method in the cbt parses its own arguments and constructs the appropriate call to the service. It would be nice to refactor these methods to use an argument struct that is composed by another function that _only_ parses arguments.
Why to do this:
- In some cases, the current situation results in a lot of duplicated call (e.g. `doLookup()` and `doRead()`).
- Each `do*()` method has multiple concerns--arg parsing and composing the calls to the service. This breaks the principle of orthogonality.
Contributor guide
Assessment
This issue has not been assessed yet.