Class: Xcake::ShellScriptBuildPhase
- Inherits:
-
BuildPhase
- Object
- BuildPhase
- Xcake::ShellScriptBuildPhase
- Defined in:
- lib/xcake/dsl/build_phase/shell_script_build_phase.rb
Overview
This class is used to represent a shell script build phase
Instance Attribute Summary collapse
-
#name ⇒ Object
The name of the build phase as shown in Xcode.
-
#script ⇒ Object
String coataining the contents of the script to run.
Instance Method Summary collapse
- #build_phase_type ⇒ Object
- #configure_native_build_phase(native_build_phase, _context) ⇒ Object
- #to_s ⇒ Object
Methods inherited from BuildPhase
Constructor Details
This class inherits a constructor from Xcake::BuildPhase
Instance Attribute Details
#name ⇒ Object
The name of the build phase as shown in Xcode
6 7 8 |
# File 'lib/xcake/dsl/build_phase/shell_script_build_phase.rb', line 6 def name @name end |
#script ⇒ Object
String coataining the contents of the script to run
9 10 11 |
# File 'lib/xcake/dsl/build_phase/shell_script_build_phase.rb', line 9 def script @script end |
Instance Method Details
#build_phase_type ⇒ Object
11 12 13 |
# File 'lib/xcake/dsl/build_phase/shell_script_build_phase.rb', line 11 def build_phase_type Xcodeproj::Project::Object::PBXShellScriptBuildPhase end |
#configure_native_build_phase(native_build_phase, _context) ⇒ Object
15 16 17 18 |
# File 'lib/xcake/dsl/build_phase/shell_script_build_phase.rb', line 15 def configure_native_build_phase(native_build_phase, _context) native_build_phase.name = name native_build_phase.shell_script = script.strip_heredoc end |
#to_s ⇒ Object
20 21 22 |
# File 'lib/xcake/dsl/build_phase/shell_script_build_phase.rb', line 20 def to_s "BuildPhase<#{name}>" end |