Class: Tug::BuildTool
- Inherits:
-
Object
- Object
- Tug::BuildTool
- Defined in:
- lib/tug/tool/buildtool.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#config ⇒ Object
readonly
Returns the value of attribute config.
Class Method Summary collapse
Instance Method Summary collapse
- #build(workspace, scheme) ⇒ Object
-
#initialize(config) ⇒ BuildTool
constructor
A new instance of BuildTool.
Constructor Details
#initialize(config) ⇒ BuildTool
Returns a new instance of BuildTool.
17 18 19 |
# File 'lib/tug/tool/buildtool.rb', line 17 def initialize(config) @config = config end |
Instance Attribute Details
#config ⇒ Object (readonly)
Returns the value of attribute config.
4 5 6 |
# File 'lib/tug/tool/buildtool.rb', line 4 def config @config end |
Class Method Details
.tool_for_config(config) ⇒ Object
7 8 9 10 11 12 13 14 |
# File 'lib/tug/tool/buildtool.rb', line 7 def tool_for_config(config) case config.downcase when "inhouse", "release", /release/, /inhouse/ Tug::BuildToolArchive.new(config) else Tug::BuildToolBuild.new(config) end end |
Instance Method Details
#build(workspace, scheme) ⇒ Object
21 22 23 |
# File 'lib/tug/tool/buildtool.rb', line 21 def build(workspace, scheme) system("xcodebuild #{build_options(workspace, scheme)}") end |