From 1f30deb36eb0dfd6996dfdd1be28c24119c96631 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miko=C5=82aj=20Pich?= Date: Fri, 23 Nov 2018 12:38:55 +0100 Subject: [PATCH] Add config for travis ci (#185) --- .circleci/config.yml | 2 +- .gitignore | 4 +- .travis.yml | 65 ++++++++++++++++++++++++++++++++ README.md | 5 ++- app/build.gradle | 6 +-- app/sonarqube.gradle | 6 +-- app/src/main/play/pl-PL/whatsnew | 7 +--- build.gradle | 2 +- 8 files changed, 80 insertions(+), 17 deletions(-) create mode 100644 .travis.yml diff --git a/.circleci/config.yml b/.circleci/config.yml index 789123fa..717d3bdf 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -202,4 +202,4 @@ workflows: tags: only: /\d+\.\d+\.\d+/ branches: - ignore: /.*/ \ No newline at end of file + ignore: /.*/ diff --git a/.gitignore b/.gitignore index 11fb79e5..6bc531b6 100644 --- a/.gitignore +++ b/.gitignore @@ -44,7 +44,7 @@ local.properties ehthumbs.db Thumbs.db .idea/caches/ -./app/key.p12 -./app/upload-key.jks +app/key.p12 +app/upload-key.jks *.log .idea/assetWizardSettings.xml diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 00000000..efef4fee --- /dev/null +++ b/.travis.yml @@ -0,0 +1,65 @@ +language: android +jdk: oraclejdk8 + +env: + global: + - ANDROID_API_LEVEL=28 + - ANDROID_BUILD_TOOLS_VERSION=28.0.3 + +cache: + directories: + - $HOME/.gradle/caches/ + - $HOME/.gradle/wrapper/ + +branches: + only: + - master + +android: + licenses: + - android-sdk-preview-license-.+ + - android-sdk-license-.+ + - google-gdk-license-.+ + components: + - tools + - platform-tools + # The BuildTools version used by your project + - build-tools-$ANDROID_BUILD_TOOLS_VERSION + # The SDK version used to compile your project + - android-$ANDROID_API_LEVEL + # Additional components + - extra-google-google_play_services + - extra-google-m2repository + - extra-android-m2repository + - addon-google_apis-google-$ANDROID_API_LEVEL + # Android emulator + - android-19 + - sys-img-armeabi-v7a-android-19 + +before_script: + # Launch emulator before the execution + - echo no | android create avd --force -n test -t android-19 --abi armeabi-v7a + - emulator -avd test -no-audio -no-window & + - android-wait-for-emulator + - adb shell input keyevent 82 & + - "curl -H 'Cache-Control: no-cache' https://raw.githubusercontent.com/fossas/fossa-cli/master/install.sh | sudo bash" + +script: + - ./gradlew build -x test -x lint -x fabricGenerateResourcesRelease -x packageRelease --stacktrace --daemon + - fossa --no-ansi || true + - ./gradlew lint -x fabricGenerateResourcesRelease --stacktrace --daemon + - ./gradlew test -x fabricGenerateResourcesRelease --stacktrace --daemon + - ./gradlew createDebugCoverageReport --stacktrace -PdisableCrashlytics --daemon + - ./gradlew jacocoTestReport --stacktrace --daemon + - if [ "$TRAVIS_PULL_REQUEST" != "false" ] || [ "$TRAVIS_BRANCH" == "master" ]; then + ./gradlew sonarqube -x test -x lint -x fabricGenerateResourcesRelease -Dsonar.host.url=$SONAR_HOST -Dsonar.organization=$SONAR_ORG -Dsonar.login=$SONAR_KEY -Dsonar.branch.name=$TRAVIS_BRANCH -PdisableCrashlytics --stacktrace --daemon; + fi + - | + if [ $TRAVIS_TAG ]; then + openssl aes-256-cbc -d -in ./app/key-encrypted.p12 -k $ENCRYPT_KEY >> ./app/key.p12; + openssl aes-256-cbc -d -in ./app/upload-key-encrypted.jks -k $ENCRYPT_KEY >> ./app/upload-key.jks; + ./gradlew publishRelease --stacktrace; + fi + +after_success: + - bash <(curl -s https://codecov.io/bash) diff --git a/README.md b/README.md index 9951cb8e..6c5ad04f 100644 --- a/README.md +++ b/README.md @@ -1,16 +1,17 @@ # Wulkanowy [![CircleCI](https://img.shields.io/circleci/project/github/wulkanowy/wulkanowy/master.svg?style=flat-square)](https://circleci.com/gh/wulkanowy/wulkanowy) +[![Travis](https://img.shields.io/travis/wulkanowy/wulkanowy/master.svg?style=flat-square)](https://travis-ci.com/wulkanowy/wulkanowy) [![Bitrise](https://img.shields.io/bitrise/daeff1893f3c8128/master.svg?token=Hjm1ACamk86JDeVVJHOeqQ&style=flat-square)](https://www.bitrise.io/app/daeff1893f3c8128) [![Codecov](https://img.shields.io/codecov/c/github/wulkanowy/wulkanowy/master.svg?style=flat-square)](https://codecov.io/gh/wulkanowy/wulkanowy) [![BCH compliance](https://bettercodehub.com/edge/badge/wulkanowy/wulkanowy?branch=master)](https://bettercodehub.com/) -[![Scrutinizer](https://img.shields.io/scrutinizer/g/wulkanowy/wulkanowy.svg?style=flat-square)](https://scrutinizer-ci.com/g/wulkanowy/wulkanowy/?branch=master) [![Discord](https://img.shields.io/discord/390889354199040011.svg?style=flat-square)](https://discord.gg/vccAQBr) [![FOSSA Status](https://app.fossa.io/api/projects/custom%2B5644%2Fgit%40github.com%3Awulkanowy%2Fwulkanowy.git.svg?type=shield)](https://app.fossa.io/projects/custom%2B5644%2Fgit%40github.com%3Awulkanowy%2Fwulkanowy.git?ref=badge_shield) -[Pobierz wersję beta](https://play.google.com/store/apps/details?id=io.github.wulkanowy&utm_source=vcs) +[Pobierz wersję beta z Google Play](https://play.google.com/store/apps/details?id=io.github.wulkanowy&utm_source=vcs) [Pobierz wersję DEV](https://bitrise-redirector.herokuapp.com/v0.1/apps/daeff1893f3c8128/builds/master/artifacts/0) +[(Więcej wersji DEV)](https://wulkanowy.github.io/dev.html) Androidowy klient dziennika VULCAN UONET+. diff --git a/app/build.gradle b/app/build.gradle index f46bc77a..7532ba7c 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -25,8 +25,8 @@ android { testApplicationId "io.github.tests.wulkanowy" minSdkVersion 15 targetSdkVersion 28 - versionCode 16 - versionName "0.5.2" + versionCode 18 + versionName "0.5.4" multiDexEnabled true testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" vectorDrawables.useSupportLibrary = true @@ -78,7 +78,7 @@ ext.androidx_version = "1.0.0" dependencies { implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version" - implementation('com.github.wulkanowy:api:ddb1baa') { exclude module: "threetenbp" } + implementation('com.github.wulkanowy:api:a80b8e5') { exclude module: "threetenbp" } implementation "androidx.legacy:legacy-support-v4:$androidx_version" implementation "androidx.appcompat:appcompat:$androidx_version" diff --git a/app/sonarqube.gradle b/app/sonarqube.gradle index 9fd890d8..52fd2dd8 100644 --- a/app/sonarqube.gradle +++ b/app/sonarqube.gradle @@ -4,10 +4,10 @@ sonarqube { //noinspection GroovyAssignabilityCheck properties { - def libraries = project.android.sdkDirectory.getPath() + "/platforms/android-27/android.jar" + def libraries = project.android.sdkDirectory.getPath() + "/platforms/android-28/android.jar" - property "sonar.projectName", GROUP_ID + ":app" - property "sonar.projectKey", GROUP_ID + ":app" + property "sonar.projectName", "io.github.wulkanowy:app" + property "sonar.projectKey", "io.github.wulkanowy:app" property "sonar.sources", "src/main/java" property "sonar.exclusions", "build/**,**/*.png,*.iml, **/*generated*," diff --git a/app/src/main/play/pl-PL/whatsnew b/app/src/main/play/pl-PL/whatsnew index ff412b22..205817c5 100644 --- a/app/src/main/play/pl-PL/whatsnew +++ b/app/src/main/play/pl-PL/whatsnew @@ -1,5 +1,2 @@ -Wersja 0.5.1: -- dodano wagę ocen na liście -- naprawiono błędy podczas logowania -- zmieniono nasycenie kolorów ocen -- wyłączenie synchronizacji podczas wakacji +Wersja 0.5.4: +- naprawiono błąd logowania diff --git a/build.gradle b/build.gradle index 1b4538bb..54388286 100644 --- a/build.gradle +++ b/build.gradle @@ -1,5 +1,5 @@ buildscript { - ext.kotlin_version = '1.3.0' + ext.kotlin_version = '1.3.10' repositories { mavenCentral() google()