Method: Pod::Specification::DSL#resource_bundles=

Defined in:
lib/cocoapods-core/specification/dsl.rb

#resource_bundles=(*resource_bundles) ⇒ Object

This attribute allows to define the name and the file of the resource bundles which should be built for the Pod. They are specified as a hash where the keys represent the name of the bundles and the values the file patterns that they should include.

For building the Pod as a static library, we strongly recommend library developers to adopt resource bundles as there can be name collisions using the resources attribute.

The names of the bundles should at least include the name of the Pod to minimise the chance of name collisions.

To provide different resources per platform namespaced bundles must be used.

Examples:


spec.ios.resource_bundle = { 'MapBox' => 'MapView/Map/Resources/*.png' }

spec.resource_bundles = {
    'MapBox' => ['MapView/Map/Resources/*.png'],
    'MapBoxOtherResources' => ['MapView/Map/OtherResources/*.png']
  }

Parameters:

  • resource_bundles (Hash{String=>String}, Hash{String=>Array<String>})

    A hash where the keys are the names of the resource bundles and the values are their relative file patterns.



1448
1449
1450
1451
1452
# File 'lib/cocoapods-core/specification/dsl.rb', line 1448

attribute :resource_bundles,
:types => [String, Array],
:container => Hash,
:file_patterns => true,
:singularize => true