Last active
September 19, 2023 06:20
-
-
Save rodydavis/d94223e202d03373f1af7ef22b46c141 to your computer and use it in GitHub Desktop.
Using Fastlane for Flutter to deploy iOS, Mac, Android and Web
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This file contains the fastlane.tools configuration | |
# You can find the documentation at https://docs.fastlane.tools | |
# | |
# For a list of all available actions, check out | |
# | |
# https://docs.fastlane.tools/actions | |
# | |
# For a list of all available plugins, check out | |
# | |
# https://docs.fastlane.tools/plugins/available-plugins | |
# | |
# Uncomment the line if you want fastlane to automatically update itself | |
# update_fastlane | |
default_platform(:ios) | |
platform :ios do | |
desc "Runs all the tests" | |
lane :test do | |
sh "flutter test" | |
end | |
desc "Deploy Beta Build" | |
lane :beta do | |
# puts "Deploying Mac App" | |
# sh "flutter build macos --profile" | |
# Dir.chdir("../macos") do | |
# sh "fastlane beta" | |
# end | |
puts "Deploying iOS App" | |
sh "flutter build ios" | |
Dir.chdir("../ios") do | |
sh "fastlane beta" | |
end | |
puts "Deploying Android App" | |
sh "flutter build appbundle" | |
Dir.chdir("../android") do | |
sh "fastlane beta" | |
end | |
end | |
desc "Deploy Release Build" | |
lane :release do | |
puts "Deploying Web App" | |
sh "flutter pub global run peanut" | |
sh "git push origin --set-upstream gh-pages" | |
# puts "Deploying MacOS App" | |
# sh "flutter build macos --profile" | |
# Dir.chdir("../macos") do | |
# sh "fastlane release" | |
# end | |
puts "Deploying iOS App" | |
sh "flutter build ios --profile" | |
Dir.chdir("../ios") do | |
sh "fastlane release" | |
end | |
puts "Deploying Android App" | |
sh "flutter build appbundle --profile" | |
Dir.chdir("../android") do | |
sh "fastlane release" | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment