Skip to content

Instantly share code, notes, and snippets.

@rodydavis
Last active June 29, 2018 20:02
Show Gist options
  • Save rodydavis/3b362548a200af9908a60f3898b1a776 to your computer and use it in GitHub Desktop.
Save rodydavis/3b362548a200af9908a60f3898b1a776 to your computer and use it in GitHub Desktop.
Fastlane Fastfiles for iOS and Android
update_fastlane
default_platform(:ios)
platform :ios do
desc "Push a new beta build to TestFlight"
lane :beta do
increment_build_number(xcodeproj: "Runner.xcodeproj")
build_app(workspace: "Runner.xcworkspace", scheme: "Runner")
upload_to_testflight(skip_waiting_for_build_processing: true)
end
desc "Push a new release build to the App Store"
lane :release do
increment_build_number(xcodeproj: "Runner.xcodeproj")
build_app(workspace: "Runner.xcworkspace", scheme: "Runner")
upload_to_app_store(submit_for_review: true,
automatic_release: true,
skip_screenshots: true,
force: true,
skip_waiting_for_build_processing: true)
end
end
//<YOUR PROJECT PATH> > android > fastlane > Fastfile
default_platform(:android)
platform :android do
desc "Runs all the tests"
lane :test do
gradle(task: "test")
end
desc "Submit a new Build to Beta"
lane :beta do
gradle(task: 'clean')
increment_version_code
sh "cd <YOUR PROJECT PATH> && flutter build apk"
upload_to_play_store(
track: 'beta',
apk: '../build/app/outputs/apk/release/app-release.apk',
skip_upload_screenshots: true,
skip_upload_images: true
)
# crashlytics
end
desc "Deploy a new version to the Google Play"
lane :deploy do
gradle(task: 'clean')
increment_version_code
sh "cd <YOUR PROJECT PATH> && flutter build apk"
upload_to_play_store(
track: 'production',
apk: '../build/app/outputs/apk/release/app-release.apk',
skip_upload_screenshots: true,
skip_upload_images: true
)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment