Ralph Bergmann Ralph Bergmann -4 years ago 254
iOS Question

How to clear Fastlane gym output directory?

I try to build my iOS app with Fastlane. That works so far but only for the first build.

If I try to rebuild the project I get this error message:

xcodebuild: error: Existing file at -resultBundlePath "xxx/output/Jenkins.result"


This is my Fastlane config:

lane :jenkins do

setup_jenkins(
force: '1',
unlock_keychain: '1',
keychain_path: "~/Library/Keychains/login.keychain",
keychain_password: "xxx",
code_signing_identity: "xxx"
)

clean_build_artifacts
clear_derived_data

gym(
workspace: "Travel.xcworkspace",
configuration: "Release",
scheme: "Jenkins",
silent: true,
clean: true,
export_method: "app-store"
)

end


What is missing to clear the output directory?

Answer Source

Use delete workspace plugin or unix shell (rm -f) or windows shell (rmdir /s /q) command.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download