forked from dashpay/dash-wallet
-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
.travis.yml
100 lines (90 loc) · 3.45 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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
language: android
jdk: oraclejdk8
env:
global:
# - ANDROID_NDK_VERSION=r15c
# - ANDROID_NDK_HOME=/opt/android-ndk
- ADB_INSTALL_TIMEOUT=20 # minutes (2 minutes by default)
# - CMAKE_VERSION=cmake-3.6.3
- ANDROID_BUILD_TOOLS_VERSION=29.0.3
- ANDROID_TARGET=android-29
before_install:
# Install SDK license so Android Gradle plugin can install deps.
- mkdir "$ANDROID_HOME/licenses" || true
- echo "d56f5187479451eabf01fb78af6dfcb131a6481e" > "$ANDROID_HOME/licenses/android-sdk-license"
- echo "24333f8a63b6825ea9c5514f83c2829b004d1fee" > "$ANDROID_HOME/licenses/android-sdk-license"
# Install the rest of tools (e.g., avdmanager).
- sdkmanager tools
# Install the system image.
- sdkmanager "system-images;android-21;default;armeabi-v7a"
# Create and start emulator for the script. Meant to race the install task.
# - echo no | avdmanager create avd --force -n test -k "system-images;android-21;default;armeabi-v7a"
# - $ANDROID_HOME/emulator/emulator -avd test -no-audio -no-window &
# - rm -rf "$ANDROID_NDK_HOME"
# - mkdir /opt/android-ndk-tmp
# - cd /opt/android-ndk-tmp
# - wget -q https://dl.google.com/android/repository/android-ndk-${ANDROID_NDK_VERSION}-linux-x86_64.zip | cat
# - unzip -q android-ndk-${ANDROID_NDK_VERSION}-linux-x86_64.zip | cat
# - mv ./android-ndk-${ANDROID_NDK_VERSION} ${ANDROID_NDK_HOME}
# - cd ${ANDROID_NDK_HOME}
# - rm -rf /opt/android-ndk-tmp
- cd ${TRAVIS_BUILD_DIR}
install:
# - echo y | sdkmanager 'cmake;3.6.4111459' | grep -v "=$"
- echo y | sdkmanager 'lldb;3.0' | grep -v "=$"
before_script:
# - export ANDROID_NDK_HOME=$ANDROID_NDK_HOME
# - android-wait-for-emulator
# - adb shell settings put global window_animation_scale 0 &
# - adb shell settings put global transition_animation_scale 0 &
# - adb shell settings put global animator_duration_scale 0 &
# - adb shell input keyevent 82 &
android:
components:
# Uncomment the lines below if you want to
# use the latest revision of Android SDK Tools
- tools
- platform-tools
- tools
- build-tools-$ANDROID_BUILD_TOOLS_VERSION
- $ANDROID_TARGET
- extra-google-google_play_services
# Support library
- extra-android-support
# Latest artifacts in local repository
- extra-google-m2repository
- extra-android-m2repository
# Specify at least one system image
# - sys-img-armeabi-v7a-android-$ANDROID_API_LEVEL
#allow licenses
licenses:
- 'android-sdk-preview-license-+'
- 'android-sdk-license-.+'
- 'google-gdk-license-.+'
#Notifications
notifications:
email: false
script:
- openssl aes-256-cbc -K $encrypted_5c8f4d70d644_key -iv $encrypted_5c8f4d70d644_iv -in .deploy/service.properties.enc -out service.properties -d
- openssl aes-256-cbc -K $encrypted_f761570c4ae9_key -iv $encrypted_f761570c4ae9_iv -in .deploy/google-services.json.enc -out wallet/google-services.json -d
- ./gradlew test
- ./gradlew assemble_testNet3Debug
- rm -rf .gradle/4.4
- ./gradlew assembleProdDebug
- ./gradlew assembleProdRelease
before_deploy:
- openssl aes-256-cbc -K $encrypted_945ec88d7d8f_key -iv $encrypted_945ec88d7d8f_iv -in .deploy/id_rsa.enc -out .deploy/id_rsa -d
- ls -ll .deploy/
deploy:
# deploy feature branch if tagged
- provider: script
script: bash .deploy/deploy.sh feature
skip_cleanup: true
on:
tags: true
# deploy master
- provider: script
script: bash .deploy/deploy.sh master
skip_cleanup: true
on:
branch: master