How to automate xcode clean process using fastlane Fastfile lane

5.4k views Asked by At

I am looking for a way to automate xcode clean process using fastlate.

What I am looking to achieve:

  1. Clear Derived Data Folder
  2. Clean build folder
  3. Clean
  4. Build

So far I automated the derived data folder

lane :clean do
  clear_derived_data
end
1

There are 1 answers

0
Sulfkain On BEST ANSWER

You have achieve 1,2 and 3, but for 4, you need to use Gym It's easy to use, follow his guide https://docs.fastlane.tools/actions/gym/

lane :cleanAndBuild do
  clear_derived_data
  gym( my_params )
end