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

cli: use Cobra's positional argument validation #24399

Merged

Commits on Apr 2, 2018

  1. cli: use Cobra's positional argument validation

    Positional argument validation was added to spf13/cobra in
    spf13/cobra#284, but our cli still
    relies on custom validation in each of the "run" functions.
    This validation is unstandardized and overly permissive in
    certain cases. This change fixes this by replacing our custom
    logic with validation expressed using Cobra's `PositionalArgs`
    validators.
    
    Release note: None
    nvanbenschoten committed Apr 2, 2018
    Configuration menu
    Copy the full SHA
    77a8492 View commit details
    Browse the repository at this point in the history
  2. cli: correctly indicate required arguments

    Required args should not be put in square brackets.
    
    Release note: None
    nvanbenschoten committed Apr 2, 2018
    Configuration menu
    Copy the full SHA
    5f21e76 View commit details
    Browse the repository at this point in the history