This commit is contained in:
Thomas 2020-09-20 18:35:43 +02:00
parent cd5e23364d
commit 36f5f73a47
1 changed files with 26 additions and 10 deletions

View File

@ -51,7 +51,27 @@ before_script:
- sdkmanager --sdk_root=${ANDROID_HOME} "build-tools;${ANDROID_BUILD_TOOLS}"
# Not necessary, but just for surity
- chmod +x ./gradlew
- chmod +x ./gradle
stages:
- build-and-test
- tag
.no-upload: &no-upload
stage: build-and-test
retry: 2
# Make Project
assembleDebug:
<<: *no-upload
cache:
key: "${CI_COMMIT_TAG}"
paths:
- app/build/outputs/apk/fdroid_acad/debug/app-fdroid_acad-debug.apk
- app/build/outputs/apk/fdroid_full/debug/app-fdroid_full-debug.apk
policy: push
script:
- ./gradlew assembleDebug
# Basic android and gradle stuff
# Check linting
@ -60,21 +80,17 @@ lintFdroid_acadDebug:
stage: build
script:
- ./gradlew -Pci --console=plain :app:lintFdroid_acadDebug -PbuildDir=lint
except:
- tags
lintFdroid_fullDebug:
interruptible: true
stage: build
script:
- ./gradlew -Pci --console=plain :app:lintFdroid_fullDebug -PbuildDir=lint
# Make Project
assembleDebug:
interruptible: true
stage: build
script:
- ./gradlew assembleDebug
artifacts:
paths:
- app/build/outputs/
except:
- tags
## PROTECTED VARIABLES TO SET IN GITLAB:
# - GITLAB_API_TOKEN: token you create on Gitlab