Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Cobra functionality to validate arguments. #1125

Open
elhimov opened this issue Mar 13, 2025 · 0 comments · May be fixed by #1126
Open

Use Cobra functionality to validate arguments. #1125

elhimov opened this issue Mar 13, 2025 · 0 comments · May be fixed by #1126
Assignees
Labels
code health Improve code readability, simplify maintenance and so on

Comments

@elhimov
Copy link
Contributor

elhimov commented Mar 13, 2025

Cobra's Command has built-in functionality to perform arguments validation. Some commands use it, but some doesn't. One of the reason might be in that Cobra's validation errors are displayed as ordinary text and often look unnoticeable while general logger errors are displayed as red bold text. Consider making Cobra's errors look similar to general logger errors.

@elhimov elhimov self-assigned this Mar 13, 2025
@elhimov elhimov added the code health Improve code readability, simplify maintenance and so on label Mar 13, 2025
elhimov added a commit that referenced this issue Mar 13, 2025
elhimov added a commit that referenced this issue Mar 14, 2025
elhimov added a commit that referenced this issue Mar 14, 2025
@elhimov elhimov linked a pull request Mar 14, 2025 that will close this issue
elhimov added a commit that referenced this issue Mar 14, 2025
elhimov added a commit that referenced this issue Mar 17, 2025
elhimov added a commit that referenced this issue Mar 18, 2025
elhimov added a commit that referenced this issue Mar 18, 2025
elhimov added a commit that referenced this issue Mar 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
code health Improve code readability, simplify maintenance and so on
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant