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

(PUP-11693) Global OptionParser ignores partially matched invalid params #9313

Merged
merged 1 commit into from
Apr 15, 2024

Commits on Apr 15, 2024

  1. (PUP-11693) Global OptionParser ignores partially matched invalid params

    This commit modifies how partial matches are handled when parsing global
    command line options. Before, Puppet would accept and do nothing with options
    global options that use '-' instead of '_'. For example, it would accept
    '--show-diff' and do nothing when the correct name is '--show_diff'.
    
    With this change, while handling any global options given in the command line
    options, if the command line option does not match existing global options, it
    will convert '-' to '_' and vice versa. Then, check if that matches a valid global
    option. Additionally, if the command line option needs to convert '-' to '_' or
    vice versa, Puppet will also warn to let the user know a partial match was
    detected and that this behavior will be deprecated in Puppet 9.
    AriaXLi committed Apr 15, 2024
    Configuration menu
    Copy the full SHA
    c579786 View commit details
    Browse the repository at this point in the history