Class: Itamae::RecipeLoader
- Inherits:
-
Object
- Object
- Itamae::RecipeLoader
- Defined in:
- lib/itamae/recipe_loader.rb,
lib/itamae/recipe_loader/version.rb
Constant Summary collapse
- VERSION =
'0.1.0'
Instance Attribute Summary collapse
-
#backend ⇒ Object
readonly
Returns the value of attribute backend.
-
#runner ⇒ Object
readonly
Returns the value of attribute runner.
Class Method Summary collapse
Instance Method Summary collapse
- #all_recipe_names(reject_recipes = ['recipes']) ⇒ Object
-
#initialize(recipe_files, backend_type, options) ⇒ RecipeLoader
constructor
A new instance of RecipeLoader.
Constructor Details
#initialize(recipe_files, backend_type, options) ⇒ RecipeLoader
Returns a new instance of RecipeLoader.
9 10 11 12 13 14 15 |
# File 'lib/itamae/recipe_loader.rb', line 9 def initialize(recipe_files, backend_type, ) self.class.logger_init() @targets = [] backend = Itamae::Backend.create(backend_type, ) @runner = Itamae::Runner.new(backend, ) @runner.load_recipes(recipe_files) end |
Instance Attribute Details
#backend ⇒ Object (readonly)
Returns the value of attribute backend.
6 7 8 |
# File 'lib/itamae/recipe_loader.rb', line 6 def backend @backend end |
#runner ⇒ Object (readonly)
Returns the value of attribute runner.
7 8 9 |
# File 'lib/itamae/recipe_loader.rb', line 7 def runner @runner end |
Class Method Details
Instance Method Details
#all_recipe_names(reject_recipes = ['recipes']) ⇒ Object
22 23 24 |
# File 'lib/itamae/recipe_loader.rb', line 22 def all_recipe_names(reject_recipes = ['recipes']) recipe_names(@runner.children) - reject_recipes end |