Skip to content

codecov/example-java-gradle

Repository files navigation

Codecov Java Example

https://codecov.io @codecov hello@codecov.io

This repository serves as an example on how to use Codecov Global for Java with a Gradle build script.

Usage

Add Jacoco plugin

Gradle ships with a JaCoCo plugin. Just add it to your build.gradle.

apply plugin: 'jacoco'

And enable the jacoco XML report.

jacocoTestReport { reports { xml.enabled true } }

Circle CI

Add to your circle.yml file.

test: post: - if [ -e ./gradlew ]; then ./gradlew jacocoTestReport;else gradle jacocoTestReport;fi - pip install --user codecov && codecov

Another option is our Bash uploader

Private Repos

Add to your .travis.yml file.

test: post: - if [ -e ./gradlew ]; then ./gradlew jacocoTestReport;else gradle jacocoTestReport;fi - pip install --user codecov && codecov: environment: CODECOV_TOKEN: uuid-repo-token

View source and learn more about Codecov Global Uploader

About

No description or website provided.

Topics

Resources

License

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 10

Languages