Class: Gemi::Command
- Inherits:
-
Object
- Object
- Gemi::Command
- Defined in:
- lib/gemi/commands.rb
Instance Method Summary collapse
- #build(ruby) ⇒ Object
-
#initialize(type, gem_names, yamls) ⇒ Command
constructor
A new instance of Command.
Constructor Details
Instance Method Details
#build(ruby) ⇒ Object
13 14 15 16 17 18 19 20 21 22 |
# File 'lib/gemi/commands.rb', line 13 def build(ruby) if @gems.any?{|gem| gem.version or gem.[@type]} @gems.map{|gem| build_command(gem.to_command(@type), ruby) }.join(" ; ") else gem_names = @gems.map(&:name).join(" ") build_command(gem_names, ruby) end end |