Module: XcodeProjSetting
- Defined in:
- lib/xcodeproj_setting.rb
Class Method Summary collapse
- .change_setting(project_filepath, target_name, project_configuration, key, new_value, verbose) ⇒ Object
- .print_setting(project_filepath, target_name, project_configuration, key) ⇒ Object
Class Method Details
.change_setting(project_filepath, target_name, project_configuration, key, new_value, verbose) ⇒ Object
5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/xcodeproj_setting.rb', line 5 def self.change_setting(project_filepath, target_name, project_configuration, key, new_value, verbose) configuration = self.get_config_obj(project_filepath, target_name, project_configuration, verbose) if configuration.nil? puts "ERROR: Unable to find configuration '#{project_configuration}'!" exit -12 end puts "*** Setting Xcode Project's #{key} to '#{new_value}' on target '#{target_name}' for configuration '#{project_configuration}'" if verbose == true configuration.build_settings[key] = new_value configuration.project.save end |
.print_setting(project_filepath, target_name, project_configuration, key) ⇒ Object
20 21 22 23 24 25 26 27 28 29 |
# File 'lib/xcodeproj_setting.rb', line 20 def self.print_setting(project_filepath, target_name, project_configuration, key) configuration = self.get_config_obj(project_filepath, target_name, project_configuration, false) if configuration.nil? puts "ERROR: Unable to find configuration '#{project_configuration}'!" exit -12 end puts configuration.build_settings[key] end |