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

(SDK-321) add pdk validate help #183

Merged
merged 1 commit into from
Jul 24, 2017

Conversation

DavidS
Copy link
Contributor

@DavidS DavidS commented Jul 21, 2017

No description provided.

@DavidS DavidS force-pushed the sdk-321-pdk-validate-help branch from 75b9aad to 2b46724 Compare July 21, 2017 11:13
@@ -17,6 +17,11 @@ module PDK::CLI
flag :a, 'auto-correct', _('automatically correct problems (where possible)')

run do |opts, args, _cmd|
if args == ['help']

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a Cri way to do this? For other commands (test, new) it looks like we get the help subcommand for free. But it looks like 'validate' is different since on it's own (just 'pdk validate') it is a valid command

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding @validate_cmd.add_command Cri::Command.new_basic_help works

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

validate is "special" because the choice of validator conflicts with CRI's parsing of validate help. Try it, acceptance tests will fail.

@DavidS DavidS merged commit a80a207 into puppetlabs:master Jul 24, 2017
@DavidS DavidS deleted the sdk-321-pdk-validate-help branch July 24, 2017 09:49
@scotje scotje added the feature label Jul 24, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants