module Pod::Podfile::DSL
Public Class Methods
when enable, `pod` function will skip all pods without 'prebuild => true'
# File lib/cocoapods-binary-gcp/helper/feature_switches.rb, line 17 def self.enable_prebuild_patch(value) @@enable_prebuild_patch = value end
Public Instance Methods
Enable prebuiding for all pods it has a lower priority to other binary settings
# File lib/cocoapods-binary-gcp/Main.rb, line 11 def all_binary! DSL.prebuild_all = true end
-
excepts: an array of name
# File lib/cocoapods-binary-gcp/Main.rb, line 16 def all_binary_except(excepts) DSL.prebuild_all = true DSL.except_binary_list = excepts end
Enable bitcode for prebuilt frameworks
# File lib/cocoapods-binary-gcp/Main.rb, line 22 def enable_bitcode_for_prebuilt_frameworks! DSL.bitcode_enabled = true end
Don't remove source code of prebuilt pods It may speed up the pod install if git didn't include the `Pods` folder
# File lib/cocoapods-binary-gcp/Main.rb, line 29 def keep_source_code_for_prebuilt_frameworks! DSL.dont_remove_source_code = true end
Add custom xcodebuild option to the prebuilding action
You may use this for your special demands. For example: the default archs in dSYMs of prebuilt frameworks is 'arm64 armv7 x86_64', and no 'i386' for 32bit simulator. It may generate a warning when building for a 32bit simulator. You may add following to your podfile
` set_custom_xcodebuild_options_for_prebuilt_frameworks :simulator => "ARCHS=$(ARCHS_STANDARD)" `
Another example to disable the generating of dSYM file:
` set_custom_xcodebuild_options_for_prebuilt_frameworks "DEBUG_INFORMATION_FORMAT=dwarf"`
@param [String or Hash] options
If is a String, it will apply for device and simulator. Use it just like in the commandline. If is a Hash, it should be like this: { :device => "XXXXX", :simulator => "XXXXX" }
# File lib/cocoapods-binary-gcp/Main.rb, line 74 def set_custom_xcodebuild_options_for_prebuilt_frameworks(options) if options.kind_of? Hash DSL.custom_build_options = [ options[:device] ] unless options[:device].nil? DSL.custom_build_options_simulator = [ options[:simulator] ] unless options[:simulator].nil? elsif options.kind_of? String DSL.custom_build_options = [options] DSL.custom_build_options_simulator = [options] else raise "Wrong type." end end
Options hash depends on:
-
bucket: bucketName
# File lib/cocoapods-binary-gcp/Main.rb, line 49 def use_gcp_cache(options) DSL.shared_cache_enabled = true DSL.shared_gcp_cache_enabled = true DSL.gcp_options = options end