Remove build phase script “[CP] Check Pods Manifest.lock”

Reva Yoga Pradana
2 min readJun 16, 2021

In our company, sometimes we found a problem that our build phase script "[CP] Check Pods Manifest.lock" got timeout in CircleCI, without clear reason.

Timeout on running script "[CP] Check Pods Manifest.lock"

Then, we decide to “remove” that script from our xcodeproject, because we think that we don't need that "extra step" to make sure our installed pods is the correct ones. We thought our current setup of Cocoapodsis already good.

Btw, this are our setup of Cocoapods, in our iOS App:

  1. Commit Podfile with declare exact version for it's library
  2. Git ignore the Podfile.lock
  3. Git ignore the folder Pods
  4. Always do pod install in the beginning (before compiling the app)

I think we’ll need that script if we’re not doing step 2 and 3.

Then, how we do it (removing the build phase script)? We do that by this script, that called in Fastlane.

auto remove script using Fastlane

You can also remove it by using Podfile, in step post_integrate, like this:

auto remove script using Podfile

Why we need to do it via script? Because:

  • if we do it manually, the script will always appear again after pod install
  • we don’t commit the xcodeproject

And this is the result:

before script removed in xcodeproject
after script removed in xcodeproject
Our log that indicating the script was removed

Our build success compiled. Since this is still an experiment, I’ll updating this post whenever something unnecessary happened.

--

--

Reva Yoga Pradana

Engineering Manager — Software Engineer — iOS — Infra @ OVO.id | ex Bukalapak.com