Create APK's in deployToServer- and deployToFDroid-lane for GitHub

This commit is contained in:
Julian Raufelder 2021-02-16 15:07:26 +01:00
parent 2452ddb5a2
commit 0c3671e747
No known key found for this signature in database
GPG Key ID: 17EE71F6634E381D

View File

@ -28,9 +28,8 @@ platform :android do |options|
FileUtils.cp(release_note_path_en, "metadata/android/fr-FR/changelogs/default.txt") FileUtils.cp(release_note_path_en, "metadata/android/fr-FR/changelogs/default.txt")
deployToPlaystore(beta:options[:beta]) deployToPlaystore(beta:options[:beta])
deployToServer(beta:options[:beta])
if options[:beta] deployToFDroid(beta:options[:beta])
puts "Skipping deployment to server cause there isn't currently a beta channel"
slack( slack(
default_payloads: [], # reduce the notification to the minimum default_payloads: [], # reduce the notification to the minimum
@ -39,19 +38,6 @@ platform :android do |options|
"Changes" => File.read(release_note_path_en) "Changes" => File.read(release_note_path_en)
} }
) )
else
deployToServer(beta:options[:beta])
deployToFDroid(beta:options[:beta])
slack(
default_payloads: [], # reduce the notification to the minimum
message: ":rocket: Successfully deployed #{version} with code #{build} to the Play Store and APK store :cryptomator:",
payload: {
"Changes" => File.read(release_note_path_en)
}
)
end
end end
desc "Deploy new version to Play Store" desc "Deploy new version to Play Store"
@ -134,6 +120,9 @@ platform :android do |options|
latest_version_jsn.write(token) latest_version_jsn.write(token)
latest_version_jsn.close latest_version_jsn.close
if options[:beta]
puts "Skipping deployment to server cause there isn't currently a beta channel"
else
puts "Uploading APK and release note" puts "Uploading APK and release note"
aws_s3( aws_s3(
@ -167,6 +156,7 @@ platform :android do |options|
skip_html_upload: true, skip_html_upload: true,
apk: '' apk: ''
) )
end
FileUtils.mv("release/Cryptomator-#{version}.apk", "release/Cryptomator-#{version}_signed.apk") FileUtils.mv("release/Cryptomator-#{version}.apk", "release/Cryptomator-#{version}_signed.apk")
end end
@ -190,12 +180,4 @@ platform :android do |options|
FileUtils.cp(lane_context[SharedValues::GRADLE_APK_OUTPUT_PATH], "release/Cryptomator-#{version}_fdroid_signed.apk") FileUtils.cp(lane_context[SharedValues::GRADLE_APK_OUTPUT_PATH], "release/Cryptomator-#{version}_fdroid_signed.apk")
end end
after_all do |lane|
#error do |lane, exception|
# slack(
# message: exception.message,
# success:false
# )
end
end end