From 423fe1f6b7c5bc0ca9b53a87f636668514802ad7 Mon Sep 17 00:00:00 2001 From: Daniel Pittman <daniel@puppetlabs.com> Date: Wed, 30 Mar 2011 16:58:17 -0700 Subject: (#6749) string cli base: implement preinit CLI parsing In order to identify the full set of options we need to know the action that is being invoked; that actually requires a pre-processing step to identify that out of the global options. Notably, our spec is that options can be to the right of their declaration point, but not to the left: that means that we can now extract the full set of options, and interact with the standard Puppet option handling code, resulting in at least vaguely saner behaviour... Reviewed-By: Pieter van de Bruggen <pieter@puppetlabs.com> --- lib/puppet/string/option.rb | 1 + 1 file changed, 1 insertion(+) (limited to 'lib/puppet/string/option.rb') diff --git a/lib/puppet/string/option.rb b/lib/puppet/string/option.rb index 70d62a01f..e7b6f187c 100644 --- a/lib/puppet/string/option.rb +++ b/lib/puppet/string/option.rb @@ -2,6 +2,7 @@ class Puppet::String::Option attr_reader :parent attr_reader :name attr_reader :aliases + attr_reader :optparse attr_accessor :desc def takes_argument? -- cgit