Class: Puppet::Util::CommandLine::NilSubcommand Private
- Defined in:
- lib/puppet/util/command_line.rb
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Direct Known Subclasses
Instance Method Summary collapse
-
#initialize(command_line) ⇒ NilSubcommand
constructor
private
A new instance of NilSubcommand.
- #run ⇒ Object private
Constructor Details
#initialize(command_line) ⇒ NilSubcommand
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of NilSubcommand.
155 156 157 |
# File 'lib/puppet/util/command_line.rb', line 155 def initialize(command_line) @command_line = command_line end |
Instance Method Details
#run ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
159 160 161 162 163 164 165 |
# File 'lib/puppet/util/command_line.rb', line 159 def run if @command_line.args.include? "--version" or @command_line.args.include? "-V" puts Puppet.version else puts "See 'puppet help' for help on available puppet subcommands" end end |