Here’s a memo on how to execute Run Script only during Release builds in iOS app development.
As shown below, you can write it so that the if statement branch is executed only when the CONFIGURATION value is Release.
if [ "${CONFIGURATION}" = "Release" ]; then
echo Do something really release-like
fi
・xcode - How can I limit a “Run Script” build phase to my release configuration? - Stack Overflow
That’s all from the Gemba.