Skip to content

Instantly share code, notes, and snippets.

@toori67
Created July 29, 2018 13:14
Show Gist options
  • Save toori67/d3413f8f4acc024badcf3744639a3316 to your computer and use it in GitHub Desktop.
Save toori67/d3413f8f4acc024badcf3744639a3316 to your computer and use it in GitHub Desktop.
build spec with coverage
version: 0.2
phases:
pre_build:
commands:
build:
commands:
- echo Build started on `date`
- ./gradlew clean check assembleDebug
post_build:
commands:
- echo Build completed on `date`
- echo Connect to codecov
- export CODECOV_TOKEN={your_token}
- COV_SCRIPT=/root/.cache/codecov.sh
- if [ ! -f "$COV_SCRIPT" ]; then curl -s https://codecov.io/bash > "$COV_SCRIPT"; fi
- bash $COV_SCRIPT -t $CODECOV_TOKEN
cache:
paths:
- '/root/.gradle/caches/'
- '/root/.gradle/caches/**/*'
- '/root/.cache/codecov.sh'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment