The project is in a healthy, maintained state
CocoaPods plugin to hook xcconfig of CocoaPods targets
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
 Dependencies
 Project Readme

cocoapods-xcconfig-hooks

Test License Gem

A CocoaPods plugin to hook xcconfig of CocoaPods targets.

Installation

$ gem install cocoapods-xcconfig-hooks

Usage

Load the plugin

Load this plugin by adding the following line at the beginning of Podfile (example: here).

plugin "cocoapods-xcconfig-hooks"

Configure the plugin (optional)

In Podfile, call the config_xcconfig_hooks method to provide customization for your setup (example: here).

config_xcconfig_hooks(
  hook_dir: "path/to/xcconfig/dir",
  aggregate_targets_only: true
)

The following table explains the parameters of the config_xcconfig_hooks method.

Parameter Type Default Description
hook_dir string .xcconfigs Path to the directory containing xcconfig files (relative to the project directory)
aggregate_targets_only boolean false Whether to hook aggregate targets only (ex. Pods-App, Pods-AppUITests...)

After pod installation, the settings defined in those xcconfig files should be hooked to the project.

Order of xcconfig hooks

xcconfig files (if present in the hook_dir) are included in the following order.

  • __base__.xcconfig
  • <configuration_name>.xcconfig (ex. debug.xcconfig)
  • <TargetName>.__base__.xcconfig (ex: Pods-Example.__base__.xcconfig)
  • <TargetName>.<configuration_name>.xcconfig (ex: Pods-Example.debug.xcconfig)