Class: Mona::Package::Factory
- Inherits:
-
Object
- Object
- Mona::Package::Factory
- Includes:
- Mixins
- Defined in:
- lib/mona/package/factory.rb
Instance Method Summary collapse
Methods included from Mixins
Instance Method Details
#call(package_root, package_dirname, init_proc:) ⇒ Object
13 14 15 16 17 18 19 20 21 22 23 24 25 |
# File 'lib/mona/package/factory.rb', line 13 def call(package_root, package_dirname, init_proc:) @dependencies = Hash.new { |h, k| h[k] = [] } @current_env = Mona::Package::DEFAULT_ENV instance_exec(&init_proc) package = Mona::Package.new( name: @name, root_path: package_root, package_dirname: package_dirname, dependencies: @dependencies ).tap { check_duplicate_dependencies(_1) } end |