Skip to content

Commit

Permalink
Enables travis app building and publishing
Browse files Browse the repository at this point in the history
  • Loading branch information
hufman committed May 20, 2019
1 parent e339f04 commit 3fda4e8
Show file tree
Hide file tree
Showing 4 changed files with 43 additions and 12 deletions.
39 changes: 28 additions & 11 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,32 @@
language: android

android:
components:
- extra-google-m2repository
- extra-android-m2repository
- platform-tools
- build-tools-28.0.3
- android-24
- android-26

script: ./gradlew check

- extra-google-m2repository
- extra-android-m2repository
- platform-tools
- build-tools-28.0.3
- android-24
- android-26
before_install:
- openssl aes-256-cbc -K $encrypted_2fe89d330fd2_key -iv $encrypted_2fe89d330fd2_iv
-in keystore.jks.enc -out keystore.jks -d
script: "./gradlew check"
after_success:
- ./gradlew testGmapDebugUnitTestCoverage coveralls
- "./gradlew testGmapDebugUnitTestCoverage coveralls"
- "./gradlew assembleNomap"
- "echo Found the following artifacts:; find app/build/outputs"

deploy:
provider: releases
skip_cleanup: true
overwrite: true
draft: true
api_key:
secure: KP93kqGbNCsJWQKCwgUAW0cnXnOdZlzMOs+OJznYRAy6uAOKhhpCXV375M+DeyLgYrJ+YIeyw7C8ZaTSpbWu5rqCT9DMMLmo2cZ+mbUAubxtDCbmBiM7ZRrnXQpGmBMuNvdSeM42Tc8RYq9fHJph8VEovq36ZalmGr268zl2OYrDOS83BxIUDYrKNPbQtVOgk7xpejkVwovKY9GYTi+F7FAydV3rLB9P8wtOIZqgoYGgvLddZ32Cj8FhF31IXJyYaCUE9R5Kdb4vCuF0JksCv1wqrNh70nLiaR0nwhKpWGtPM+QmW/gyVvB6CxKezm/uXKX3L/YEquybI/glUxoSZHaVTTkP3pGV2nKJjcYB/LlS3yxGXZa62qHEAqu91bDPpJBgnjYztj6fO/ruCbWvk3JW0xG3HeOy5sATbTkDNKsdeRYTv4QuqvufMX2PW8H+9HgepdJk0pW6DveauqG3bOEYQOfo7K3oWfUVqB90/F/0h7uAhQz54qIKA497fgk8ocHxX3xE8u5qMkdT/99LWOhY8nzabnI7vRszJhF6gg919EkiF+bIEWai42CDb0nhC2MdKkJIKbupUQOQx1SkYIgxV/WEvGAU03zBrZmbspAq62YTDS6LqlJqTsZpTLtqxBLFEwN9IZCHIw1QDzXrJQMRRwDJaTiYUeLXKLFmCpk=
file:
- app/build/outputs/apk/nomapSentry/release/app-nomap-sentry-release.apk
- app/build/outputs/apk/nomapFirebase/release/app-nomap-firebase-release.apk
- app/build/outputs/apk/nomapNonalytics/release/app-nomap-nonalytics-release.apk
on:
tags: true
repo: hufman/AndroidAutoIdrive
14 changes: 14 additions & 0 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,24 @@ android {
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}

signingConfigs {
release
}
def isRunningOnTravis = System.getenv("CI") == "true"
if (isRunningOnTravis) {
// configure keystore
signingConfigs.release.storeFile = file("../keystore.jks")
signingConfigs.release.storePassword = System.getenv("keystore_password")
signingConfigs.release.keyAlias = System.getenv("keystore_alias")
signingConfigs.release.keyPassword = System.getenv("keystore_alias_password")
}

buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
signingConfig signingConfigs.release
}
debug {
testCoverageEnabled true
Expand Down
2 changes: 1 addition & 1 deletion app/buildtools/SentryProperties.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ project.task("sentryProperties") {
}
outputs.file("src/main/resources/sentry.properties")
doLast {
file("src/main/resources/sentry.properties").text = """dsn=${AndroidAutoIdrive_SentryDsn}
file("src/main/resources/sentry.properties").text = """dsn=${System.env.AndroidAutoIdrive_SentryDsn ? System.env.AndroidAutoIdrive_SentryDsn : AndroidAutoIdrive_SentryDsn}
"""
}
}
Expand Down
Binary file added keystore.jks.enc
Binary file not shown.

0 comments on commit 3fda4e8

Please sign in to comment.