#1175 move play listing to flavor sourceset, correct publishing task for enabled gradle play publisher and move to onSuccess

This commit is contained in:
Sean Mac Gillicuddy 2019-05-30 10:00:46 +01:00
parent 4a0d7c3695
commit e46a71a647
44 changed files with 8 additions and 8 deletions

View File

@ -54,16 +54,13 @@ script:
# - adb shell input keyevent 82 & # unlock screen by pressing menu button # - adb shell input keyevent 82 & # unlock screen by pressing menu button
# - adb -e logcat *:D > logcat.log & # - adb -e logcat *:D > logcat.log &
# - ./gradlew createKiwixDebugCoverageReport # - ./gradlew createKiwixDebugCoverageReport
- if [ $TRAVIS_TAG ] && [$TRAVIS_PULL_REQUEST == “false” ] && [ $TRAVIS_BRANCH == “release” ]; then
./gradlew publish;
fi
- if [ $TRAVIS_TAG ] && [$TRAVIS_PULL_REQUEST == “false” ] && [ $TRAVIS_BRANCH == “master” ]; then
./gradlew publish;
fi
after_success: after_success:
- bash <(curl -s https://codecov.io/bash) - bash <(curl -s https://codecov.io/bash)
- ./gradlew testdroidUploadKiwixDebug - ./gradlew testdroidUploadKiwixDebug
- if [ $TRAVIS_TAG ] && [$TRAVIS_PULL_REQUEST == “false” ] && [ $TRAVIS_BRANCH == “release” ] || [ $TRAVIS_BRANCH == “master” ]; then
./gradlew publishKiwixRelease;
fi
after_failure: after_failure:
- export LOG_DIR = ${TRAVIS_HOME}/build/kiwix/kiwix-android/app/build/outputs/reports/androidTests/connected/flavors/KIWIX/ - export LOG_DIR = ${TRAVIS_HOME}/build/kiwix/kiwix-android/app/build/outputs/reports/androidTests/connected/flavors/KIWIX/

View File

@ -180,7 +180,7 @@ def branchName = System.getenv('TRAVIS_PULL_REQUEST') ?: "false" == "false"
: System.getenv('TRAVIS_PULL_REQUEST_BRANCH') : System.getenv('TRAVIS_PULL_REQUEST_BRANCH')
def buildNumber = System.getenv('TRAVIS_BUILD_NUMBER') ?: "dev" def buildNumber = System.getenv('TRAVIS_BUILD_NUMBER') ?: "dev"
ext{ ext {
versionMajor = 2 versionMajor = 2
versionMinor = 5 versionMinor = 5
versionPatch = 0 versionPatch = 0
@ -306,6 +306,9 @@ android {
map.each { name, directory -> map.each { name, directory ->
"$name" { "$name" {
println "Configuring $name" println "Configuring $name"
if (name == "kiwix") {
return
}
if (file(directory + "/build.gradle").exists()) { if (file(directory + "/build.gradle").exists()) {
apply from: directory + "/build.gradle" apply from: directory + "/build.gradle"
} }
@ -434,7 +437,7 @@ android {
} }
play { play {
enabled = branchName == "master" enabled = branchName == "master" || branchName == "release"
serviceAccountCredentials = file("../google.json") serviceAccountCredentials = file("../google.json")
track = "alpha" track = "alpha"
resolutionStrategy = "fail" resolutionStrategy = "fail"