-
Notifications
You must be signed in to change notification settings - Fork 9
/
.travis.yml
70 lines (57 loc) · 2.63 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
# refs:
# https://github.com/sky-map-team/stardroid/blob/master/.travis.yml
language: android
jdk:
- oraclejdk8
# Use the Travis Container-Based Infrastructure
sudo: false
cache:
directories:
- ${TRAVIS_BUILD_DIR}/gradle/caches/
- ${TRAVIS_BUILD_DIR}/gradle/wrapper/dists/
env:
global:
- GRADLE_OPTS="-Xmx2048m -Xms512m"
- ANDROID_API_LEVEL=24
- ANDROID_BUILD_TOOLS_VERSION=24.0.1
- ADB_INSTALL_TIMEOUT=20 # minutes (2 minutes by default)
- APK_FILE="ThreeStepsAhead-$TRAVIS_TAG.apk"
matrix:
- EMULATOR_API_LEVEL=19 ANDROID_ABI=armeabi-v7a RELEASE=0
- EMULATOR_API_LEVEL=21 ANDROID_ABI=armeabi-v7a RELEASE=1
# - EMULATOR_API_LEVEL=23 ANDROID_ABI=google_apis/armeabi-v7a RELEASE=0
android:
components:
- tools # to get the new `repository-11.xml`
- platform-tools
- tools # to install Android SDK tools 25.1.x
- build-tools-$ANDROID_BUILD_TOOLS_VERSION
- android-$ANDROID_API_LEVEL
- android-$EMULATOR_API_LEVEL
# Latest artifacts in local repository
- extra-android-m2repository
# Specify at least one system image
- sys-img-armeabi-v7a-google_apis-$EMULATOR_API_LEVEL
before_script:
# Create and start emulator
- echo no | android create avd --force -n test -t "android-"$EMULATOR_API_LEVEL --abi $ANDROID_ABI
- emulator -avd test -no-skin -no-audio -no-window &
- android-wait-for-emulator
script:
- ./gradlew app:connectedAndroidTest -PdisablePreDex --stacktrace
- ./gradlew assembleRelease -PdisablePreDex --stacktrace
before_deploy:
- cd app/build/outputs/apk; mv app-release.apk "$APK_FILE"; ls -la; md5sum "$APK_FILE" | tee "$APK_FILE".md5; sha1sum "$APK_FILE" | tee "$APK_FILE".sha1; cd -
deploy:
provider: releases
api_key:
secure: XzT+YAkpqNutrEgdiRVKEnfdDz8pjAaHWd6T2FEAlESW1yY/gwFhD8vYTcoJO/2EbKRYauIMD/3nTUoduxXnSUXn77wpGhcDpNMzplPj8mCfe5Hv071YnHdjwHkzR1hUZWyKZal7EPoIIlotlhwt6Pa46QWIXtDhlLeYSgFE2VrlOH0idUzV3LIqISNhNEf5e7oISJuEIADBOn6yp5AfgRFF98d2HpCxN3PA3cH9oPbEXzISSJF9lw56kVARJXWffq7WTWokdNkIytKcuzL+8WV1c17oKFAEvgnftUS1+O85CzPCWgqTzunuEX5Gtg15Dyk49RUZJDbYEG+MrpjFcjq1ubqbaEraLwpsXJFJjNN/V5K306VPx5MKZrw68nQ3T9cXC69zRv4BIXOQ8+uhlL2H+RLVQq9ECkekCiSxqjvbvPJQsdYr+GcGqMp2oRWUlbvwHPgWng01cX4+gBHhZAzR2LRQJVCSP1MoY0wxxRgWvNqzXnyTvT+oFqraNSJDiEyTxYJUy7T98YKi/j3sdohshTsM1VSffEKBC1OYDqWiOSHgCiEQybenpIc8X4SYwEsXWov0YdXNNt6/nHesmPnUrk8XTVkKhHxG+lq64mdbR7ljpZSfG88gOalmFz2v8rZjlj4LvSPh+xm7G9qtPU6MEC1YtIkpi/5AVTGoRqg=
file:
- app/build/outputs/apk/$APK_FILE
- app/build/outputs/apk/$APK_FILE.md5
- app/build/outputs/apk/$APK_FILE.sha1
skip_cleanup: true
on:
repo: spezifisch/ThreeStepsAhead
tags: true
condition: $RELEASE = 1