apple_asset_catalog()
This is liable to change in the future.
Anapple_asset_catalog() rule contains resources stored in Apple asset catalog directories. This rule does not have any output on its own and can be built only as a dependency (either direct or transitive) of an apple_bundle() rule, in which case all apple_asset_catalog() rules that the bundle rule depends on are merged and placed into the final output bundle together.Arguments
name(required) #The short name for this build target.
dirs(defaults to[]) #Set of paths of Apple asset catalogs contained by this rule. All paths have to end with the
.xcassetsextension and be compatible with the asset catalog format used by Xcode.app_icon(defaults toNone) #An optional reference to a
.appiconsetcontaining a image set representing an application icon. (The extension itself should not be included.) This parameter may be specified at most once in a givenapple_bundle's transitive dependencies.launch_image(defaults toNone) #An optional reference to a
.launchimagecontaining a image set representing an application launch image. (The extension itself should not be included.) This parameter may be specified at most once in a givenapple_bundle's transitive dependencies.visibility(defaults to[]) #List of build target patterns that identify the build rules that can include this rule as a dependency, for example, by listing it in their
depsorexported_depsattributes. For more information, see visibility.licenses(defaults to[]) #Set of license files for this library. To get the list of license files for a given build rule and all of its dependencies, you can use
buck query.labels(defaults to[]) #Set of arbitrary strings which allow you to annotate a build rule with tags that can be searched for over an entire dependency tree using
buck query attrfilter().
Examples
apple_asset_catalog(
name = 'MyAssetCatalog',
dirs = [
'MyResources.xcassets',
],
)
# A asset catalog with a app icon and launch image
apple_asset_catalog(
name = 'AssetCatalog',
dirs = [ 'AssetCatalog.xcassets' ],
app_icon = 'Icon',
launch_image = 'LaunchImage',
)