Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save RobertChalmers/5d1fce11b7d1496e4c780158c844f406 to your computer and use it in GitHub Desktop.
Save RobertChalmers/5d1fce11b7d1496e4c780158c844f406 to your computer and use it in GitHub Desktop.
This script fixes all TwitterKit related warnings in XCode 10.1. Add new run script build phase with this code:
readonly MODULEMAP="${PODS_ROOT}/TwitterCore/iOS/TwitterCore.framework/Modules/module.private.modulemap"
readonly HEADER="${PODS_ROOT}/TwitterCore/iOS/TwitterCore.framework/Headers/TwitterCore.h"
if ! grep -q "TwitterCore_Private" "${MODULEMAP}"; then
cat >"${MODULEMAP}" <<EOL
module TwitterCore_Private {
}
EOL
fi
if ! grep -q "TWTRColorUtil.h" "${HEADER}"; then
cat >>"${HEADER}" <<EOL
#import "TWTRColorUtil.h"
EOL
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment