wait_xcrun plugin
Getting Started
This project is a fastlane plugin. To get started with fastlane-plugin-wait_xcrun
, add it to your project by running:
fastlane add_plugin wait_xcrun
About wait_xcrun
Wait for Xcode toolchain to come back online after switching Xcode versions.
In particular, the plugin is designed to help with issues like this: fastlane/fastlane#5435.
This kind of issue often happens on CI servers, for example when previous build was using Xcode 7.3.1 and next build is using Xcode 8. Switching Xcode version can cause Xcode toolchain commands to fail.
Example
Check out the example Fastfile
to see how to use this plugin. Try it by cloning the repo, running fastlane install_plugins
and bundle exec fastlane test
.
The recommended way is to call wait_xcrun
in before_all
hook, but after the DEVELOPER_DIR
environment variable has been set.
before_all do
# Make sure proper Xcode version is selected by CI server
# or by setting DEVELOPER_DIR environment variable
wait_xcrun
end
Run tests for this plugin
To run both the tests, and code style validation, run
rake
To automatically fix many of the styling issues, use
rubocop -a
To see the real issue "in action", make sure you have both Xcode 8 and Xcode 7.3.1 installed in /Applications
.
Specify the name of Xcode 8 and Xcode 7.3.1 apps without the .app
extension using prev_xcode
and next_xcode
options and run switch_xcode_test
lane.
# In this example Xcode 8 is installed to /Applications/Xcode.app
# Xcode 7.3.1 is installed to /Applications/Xcode7.3.1.app
bundle exec fastlane switch_xcode_test prev_xcode:Xcode next_xcode:Xcode7.3.1
Issues and Feedback
For any other issues and feedback about this plugin, please submit it to this repository.
Troubleshooting
If you have trouble using plugins, check out the Plugins Troubleshooting doc in the main fastlane
repo.
Using fastlane
Plugins
For more information about how the fastlane
plugin system works, check out the Plugins documentation.
About fastlane
fastlane
is the easiest way to automate building and releasing your iOS and Android apps. To learn more, check out fastlane.tools.