Method: Xcode::ConfigurationList#create_config
- Defined in:
- lib/xcode/configuration_list.rb
#create_config(name) {|new_config| ... } ⇒ Object
Note:
unique names are currently not enforced but likely necessary for the the target to be build successfully.
Create a configuration for this ConfigurationList. This configuration needs to have a name.
39 40 41 42 43 44 45 46 47 48 49 50 51 52 |
# File 'lib/xcode/configuration_list.rb', line 39 def create_config(name) name = ConfigurationList.symbol_config_name_to_config_name[name] if ConfigurationList.symbol_config_name_to_config_name[name] # @todo a configuration has additional fields that are ususally set with # some target information for the title. new_config = @registry.add_object(Configuration.default_properties(name)) @properties['buildConfigurations'] << new_config.identifier yield new_config if block_given? new_config.save! end |