Skip to content

Instantly share code, notes, and snippets.

@Limon-O-O
Created November 27, 2016 03:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Limon-O-O/4aac2f52761a5efa59f1522affe649f5 to your computer and use it in GitHub Desktop.
Save Limon-O-O/4aac2f52761a5efa59f1522affe649f5 to your computer and use it in GitHub Desktop.
Disables ATS in debug builds
#Disables ATS in debug builds.
INFOPLIST="${TARGET_BUILD_DIR}"/"${INFOPLIST_PATH}"
case "${CONFIGURATION}" in
"Release"|"Adhoc")
/usr/libexec/PlistBuddy -c "Set :NSAppTransportSecurity:NSAllowsArbitraryLoads NO" "${INFOPLIST}"
;;
"Debug")
/usr/libexec/PlistBuddy -c "Set :NSAppTransportSecurity:NSAllowsArbitraryLoads YES" "${INFOPLIST}"
;;
esac
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment