Class: CocoapodsMangle::Builder
- Inherits:
-
Object
- Object
- CocoapodsMangle::Builder
- Defined in:
- lib/cocoapods_mangle/builder.rb
Overview
Builds the supplied targets of a Pods Xcode project.
This is useful for building pods for mangling purposes
Constant Summary collapse
- BUILD_DIR =
'build'
- BUILT_PRODUCTS_DIR =
"#{BUILD_DIR}/Release-iphonesimulator"
Instance Method Summary collapse
-
#binaries_to_mangle ⇒ Array<String>
Gives the built binaries to be mangled.
-
#build! ⇒ Object
Build the pods project.
-
#initialize(pods_project_path, pod_target_labels) ⇒ Builder
constructor
A new instance of Builder.
Constructor Details
#initialize(pods_project_path, pod_target_labels) ⇒ Builder
Returns a new instance of Builder.
16 17 18 19 |
# File 'lib/cocoapods_mangle/builder.rb', line 16 def initialize(pods_project_path, pod_target_labels) @pods_project_path = pods_project_path @pod_target_labels = pod_target_labels end |
Instance Method Details
#binaries_to_mangle ⇒ Array<String>
Gives the built binaries to be mangled
29 30 31 |
# File 'lib/cocoapods_mangle/builder.rb', line 29 def binaries_to_mangle static_binaries_to_mangle + dynamic_binaries_to_mangle end |
#build! ⇒ Object
Build the pods project
22 23 24 25 |
# File 'lib/cocoapods_mangle/builder.rb', line 22 def build! FileUtils.remove_dir(BUILD_DIR, true) @pod_target_labels.each { |target| build_target(target) } end |