cobra
cobra copied to clipboard
feat(command): adding args to use line
Adding args
to use line.
Old:
❯ ./test
Error: accepts 1 arg(s), received 0
Usage:
test [flags]
Flags:
-h, --help help for test
-t, --toggle Help message for toggle
New:
❯ ./test
Error: accepts 1 arg(s), received 0
Usage:
test [flags] [args]
Flags:
-h, --help help for test
-t, --toggle Help message for toggle
Diff:
3c3
< test [flags]
---
> test [flags] [args]
This PR is being marked as stale due to a long period of inactivity
@jpmcb could you take a look?
Ref #842
Hi @danmx thanks for this PR - would you be able to add a test for this? Maybe in command_test.go
? A passing test will help this get reviewed and merged in
@jpmcb took me some time but I've added tests for UseLine
.
This PR exceeds the recommended size of 200 lines. Please make sure you are NOT addressing multiple issues with one PR. Note this PR might be rejected due to its size.
@marckhouzam I see that you were active recently. Could you take a look at this PR?
I addressed the previous comment about adding tests.
I had to reshuffle Command
struct optimal memory usage (fixing violations of maligned
linter) because I added another bool field.
This PR exceeds the recommended size of 200 lines. Please make sure you are NOT addressing multiple issues with one PR. Note this PR might be rejected due to its size.