Class: Chef::Knife::EnvironmentFromFile
- Defined in:
- lib/chef/knife/chop/environment_from_file.rb
Instance Method Summary collapse
-
#initialize(argv = []) ⇒ EnvironmentFromFile
constructor
——————————————————————————————————————– Create a new instance of the current class configured for the given arguments and options.
-
#load_environment(env) ⇒ Object
DLDInternet monkey patch of original.
Constructor Details
#initialize(argv = []) ⇒ EnvironmentFromFile
Create a new instance of the current class configured for the given arguments and options
12 13 14 15 16 |
# File 'lib/chef/knife/chop/environment_from_file.rb', line 12 def initialize(argv=[]) super(argv) @rsrctype = 'environment' @location = 'environments' end |
Instance Method Details
#load_environment(env) ⇒ Object
DLDInternet monkey patch of original
19 20 21 22 23 24 25 26 |
# File 'lib/chef/knife/chop/environment_from_file.rb', line 19 def load_environment(env) updated = loader.load_from("environments", env) updated.save output(format_for_display(updated)) if config[:print_after] # BEGIN DLDInternet change ui.step("Updated Environment #{updated.name}") # END DLDInternet change end |