-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
322647d
commit d868326
Showing
1 changed file
with
70 additions
and
71 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 |
---|---|---|
|
@@ -11,76 +11,57 @@ before_script: | |
|
||
# GitLab CI Stages executed in this CI | ||
stages: | ||
# - test | ||
- test | ||
- build | ||
# - deploy | ||
- deploy | ||
|
||
# Static Analysis for avaliate code smells | ||
# static_analysis: | ||
# stage: test | ||
# before_script: | ||
# - cd project/ | ||
# - mv ../docker/static_analysis.sh ./static_analysis.sh | ||
# - chmod +x ./static_analysis.sh | ||
# script: | ||
# - ./static_analysis.sh | ||
|
||
# # Run Unit Tests, verifying the code coverage | ||
# unit_test: | ||
# stage: test | ||
# before_script: | ||
# - cd project/ | ||
# - mv ../docker/test.sh ./test.sh | ||
# - chmod +x ./test.sh | ||
# script: | ||
# - ./test.sh | ||
# artifacts: | ||
# name: "reports_${CI_PROJECT_NAME}_${CI_BUILD_REF_NAME}_unit_test" | ||
# when: always | ||
# expire_in: 2 days | ||
# paths: | ||
# - project/app/build/reports/jacocoTestReport/html | ||
static_analysis: | ||
stage: test | ||
before_script: | ||
- cd project/ | ||
- mv ../docker/static_analysis.sh ./static_analysis.sh | ||
- chmod +x ./static_analysis.sh | ||
script: | ||
- ./static_analysis.sh | ||
|
||
# # Build script for generate new .APK | ||
# build: | ||
# stage: build | ||
# before_script: | ||
# - cd project/ | ||
# - git clone $KEY_STORE_REPO ./key | ||
# - mv ./key/$STORE_FILE ./app/ | ||
# - mv ../docker/build.sh ./build.sh | ||
# - chmod +x ./build.sh | ||
# script: | ||
# - fastlane update_build_number | ||
# - ./build.sh | ||
# after_script: | ||
# - rm -Rf ./app/.git/ | ||
# - rm ./app/$STORE_FILE | ||
# artifacts: | ||
# paths: | ||
# - project/app/build/outputs/apk | ||
# only: | ||
# - tags | ||
# - dev | ||
# # - master | ||
# Run Unit Tests, verifying the code coverage | ||
unit_test: | ||
stage: test | ||
before_script: | ||
- cd project/ | ||
- mv ../docker/test.sh ./test.sh | ||
- chmod +x ./test.sh | ||
script: | ||
- ./test.sh | ||
artifacts: | ||
name: "reports_${CI_PROJECT_NAME}_${CI_BUILD_REF_NAME}_unit_test" | ||
when: always | ||
expire_in: 2 days | ||
paths: | ||
- project/app/build/reports/jacocoTestReport/html | ||
|
||
# # Deploy to PlayStore in Beta Version | ||
# deploy_beta: | ||
# stage: deploy | ||
# before_script: | ||
# - cd project/ | ||
# - echo $DEPLOY_KEY_FILE >> key.json | ||
# script: | ||
# - fastlane beta | ||
# after_script: | ||
# - rm key.json | ||
# dependencies: | ||
# - build | ||
# artifacts: | ||
# paths: | ||
# - fastlane/logs | ||
# only: | ||
# - tags | ||
# Build script for generate new .APK | ||
build: | ||
stage: build | ||
before_script: | ||
- cd project/ | ||
- git clone $KEY_STORE_REPO ./key | ||
- mv ./key/$STORE_FILE ./app/ | ||
- mv ../docker/build.sh ./build.sh | ||
- chmod +x ./build.sh | ||
script: | ||
- fastlane update_build_number | ||
- ./build.sh | ||
after_script: | ||
- rm -Rf ./app/.git/ | ||
- rm ./app/$STORE_FILE | ||
artifacts: | ||
paths: | ||
- project/app/build/outputs/apk | ||
only: | ||
- tags | ||
- dev | ||
|
||
# Build of GitHub Pages | ||
pages: | ||
|
@@ -93,11 +74,29 @@ pages: | |
- git add site/ | ||
- git commit -m"Build new Pages with $CI_PIPELINE_ID" | ||
- git push https://$GITHUB_USERNAME:[email protected]/fga-gpp-mds/2018.1_Nexte.git `git subtree split --prefix site/`:gh-pages --force | ||
# only: | ||
# - dev | ||
only: | ||
- dev | ||
|
||
# Deploy to PlayStore in Beta Version | ||
deploy_beta: | ||
stage: deploy | ||
before_script: | ||
- cd project/ | ||
- echo $DEPLOY_KEY_FILE >> key.json | ||
script: | ||
- fastlane beta | ||
after_script: | ||
- rm key.json | ||
dependencies: | ||
- build | ||
artifacts: | ||
paths: | ||
- fastlane/logs | ||
only: | ||
- tags | ||
|
||
# Cache for use on next executions | ||
# cache: | ||
# key: ${CI_PROJECT_ID}2 | ||
# paths: | ||
# - .gradle/ | ||
cache: | ||
key: ${CI_PROJECT_ID}2 | ||
paths: | ||
- .gradle/ |