This repository has been archived by the owner on Jul 10, 2020. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Fixed an issue that made the overlay disappear some times. - Removed unnecessary logs - Update README - Automate sample APK publication
- Loading branch information
1 parent
cde8a62
commit 8ebe8f4
Showing
6 changed files
with
149 additions
and
68 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,48 +1,63 @@ | ||
language: android | ||
|
||
env: | ||
global: | ||
- ANDROID_API=27 | ||
- ANDROID_BUILD_TOOLS=27.0.3 | ||
|
||
android: | ||
components: | ||
# Uncomment the lines below if you want to | ||
# use the latest revision of Android SDK Tools | ||
- platform-tools | ||
- tools | ||
|
||
# The BuildTools version used by your project | ||
- build-tools-27.0.2 | ||
|
||
# The SDK version used to compile your project | ||
- android-27 | ||
|
||
# Additional components | ||
- extra-android-support | ||
- extra-google-m2repository | ||
- extra-android-m2repository | ||
- platform-tools | ||
- tools | ||
- build-tools-$ANDROID_BUILD_TOOLS | ||
- android-$ANDROID_API | ||
- extra-android-support | ||
- extra-google-m2repository | ||
- extra-android-m2repository | ||
licenses: | ||
- '.+' | ||
- ".+" | ||
|
||
jdk: | ||
- oraclejdk8 | ||
- oraclejdk8 | ||
|
||
script: ./gradlew clean test | ||
script: if [[ "$TRAVIS_TAG" ]]; then ./gradlew clean :app:assembleRelease --stacktrace; else ./gradlew clean test --stacktrace; fi | ||
|
||
branches: | ||
except: | ||
- gh-pages | ||
|
||
- images | ||
- gh-pages | ||
- travis-build | ||
- i18n | ||
|
||
notifications: | ||
email: false | ||
slack: | ||
slack: | ||
rooms: jahirfiquitiva:StCMaxV85iad38DdSMBY43xW | ||
template: | ||
- "Build <%{build_url}|#%{build_number}> (<%{compare_url}|%{commit}: '%{commit_subject}'>) by %{author} for %{repository_name}@%{branch}, %{result} in %{duration}. <%{build_url}|Check details>." | ||
template: | ||
- 'Build <%{build_url}|#%{build_number}> (<%{compare_url}|%{commit}: ''%{commit_subject}''>) by | ||
%{author} for %{repository_name}@%{branch}, %{result} in %{duration}. <%{build_url}|Check | ||
details>.' | ||
sudo: false | ||
cache: | ||
directories: | ||
- $HOME/.m2 | ||
before_script: | ||
- chmod +x gradlew | ||
- "$HOME/.android/build-cache" | ||
- "$HOME/.m2" | ||
- "$HOME/.gradle" | ||
- "$HOME/.gradle/caches/" | ||
- "$HOME/.gradle/wrapper/" | ||
before_cache: | ||
- rm -f $HOME/.gradle/caches/modules-2/modules-2.lock | ||
- rm -fr $HOME/.gradle/caches/*/plugin-resolution/ | ||
before_script: | ||
- rm -rf $TRAVIS_BUILD_DIR/app/build/outputs | ||
- chmod +x gradlew | ||
before_install: | ||
- yes | sdkmanager "platforms;android-27" | ||
- yes | sdkmanager "platforms;android-27" | ||
after_success: | ||
- chmod +x ./publish_apk.sh; ./publish_apk.sh |
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
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
#!/usr/bin/env bash | ||
if [ "$TRAVIS_PULL_REQUEST" = false ]; then | ||
if [ "$TRAVIS_TAG" ]; then | ||
cd $TRAVIS_BUILD_DIR/app/build/outputs/apk/release/ | ||
|
||
printf "\nGetting tag information\n" | ||
tagInfo="$(curl https://api.github.com/repos/${TRAVIS_REPO_SLUG}/releases/tags/${TRAVIS_TAG})" | ||
releaseId="$(echo "$tagInfo" | jq ".id")" | ||
|
||
printf "\n\n" | ||
for apk in $(find *.apk -type f); do | ||
apkName="${apk::-4}" | ||
printf "Uploading: $apkName.apk ...\n" | ||
curl "https://uploads.github.com/repos/${TRAVIS_REPO_SLUG}/releases/${releaseId}/assets?access_token=${GITHUB_API_KEY}&name=${apkName}.apk" --header 'Content-Type: application/zip' --upload-file $apkName.apk -X POST | ||
done | ||
|
||
printf "\n\nFinished uploading APK(s)\n" | ||
else | ||
printf "\nSkipping APK(s) upload because this commit does not have a tag\n" | ||
fi | ||
else | ||
printf "\nSkipping APK(s) upload because this is just a pull request\n" | ||
fi |