Last active
May 30, 2017 10:41
-
-
Save danielgomezrico/bfb2fb5732d760e766f5 to your computer and use it in GitHub Desktop.
Android / Gradle - copy apk to folder for backup after assemble. Should be run manually ( `$./gradlew assemble backupApks` )
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
// Copy assembled apks into TEST_BACKUP (must run manually) | |
task backupApks(type: Copy) { | |
if (project.hasProperty("TEST_BACKUP")) { | |
println "Backing up apks..." | |
from('build/outputs/apk/') | |
include '*prod-release.apk' | |
include '*prod-staging.apk' | |
into "${project.getProperty("TEST_BACKUP")}" | |
} else { | |
println "No backup done because TEST_BACKUP gradle variable is not defined." | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment