Add Gradle build scan plugin

This commit is contained in:
Tyler Benson 2018-04-04 21:53:28 +08:00
parent 79a9826863
commit d9d601ce71
3 changed files with 21 additions and 7 deletions

View File

@ -59,7 +59,7 @@ jobs:
- run:
name: Build Project
command: GRADLE_OPTS="-Dorg.gradle.jvmargs=-Xmx2G -Xms512M" ./gradlew clean check -x test --stacktrace --no-daemon
command: GRADLE_OPTS="-Dorg.gradle.jvmargs=-Xmx2G -Xms512M" ./gradlew clean check -x test --parallel --stacktrace --no-daemon --max-workers=6
- save_cache:
key: dd-trace-java-{{ checksum "dd-trace-java.gradle" }}-{{ .Branch }}-{{ .Revision }}
@ -106,7 +106,7 @@ jobs:
- run:
name: Run Trace Agent Tests
command: ./gradlew traceAgentTest --parallel --stacktrace --no-daemon
command: ./gradlew traceAgentTest --parallel --stacktrace --no-daemon --max-workers=6
- run:
name: Save Artifacts to (project-root)/build
@ -129,7 +129,7 @@ jobs:
- run:
name: Verify Version Scan
command: ./gradlew verifyVersionScan --parallel --stacktrace --no-daemon
command: ./gradlew verifyVersionScan --parallel --stacktrace --no-daemon --max-workers=6
- run:
name: Save Artifacts to (project-root)/build

View File

@ -11,6 +11,7 @@ buildscript {
}
plugins {
id 'com.gradle.build-scan' version '1.13'
id 'com.github.sherter.google-java-format' version '0.6'
}
@ -33,6 +34,17 @@ task traceAgentTest {}
// Applied here to allow publishing of artifactory build info
apply from: "${rootDir}/gradle/publish.gradle"
buildScan {
termsOfServiceUrl = 'https://gradle.com/terms-of-service'
termsOfServiceAgree = 'yes'
def isCI = System.getenv("CI") != null
if (isCI) {
publishAlways()
tag 'CI'
}
}
ext.gradleWrapperVersion = '4.6'
task wrapper(type: Wrapper) {
gradleVersion = gradleWrapperVersion

View File

@ -11,10 +11,12 @@ lombok { // optional: values below are the defaults
sha256 = "c5178b18caaa1a15e17b99ba5e4023d2de2ebc18b58cde0f5a04ca4b31c10e6d"
}
apply plugin: "net.ltgt.errorprone"
tasks.withType(JavaCompile) {
// workaround for: https://github.com/google/error-prone/issues/780
options.compilerArgs += ['-Xep:ParameterName:OFF']
if (JavaVersion.current().isJava8Compatible()) {
apply plugin: "net.ltgt.errorprone"
tasks.withType(JavaCompile) {
// workaround for: https://github.com/google/error-prone/issues/780
options.compilerArgs += ['-Xep:ParameterName:OFF']
}
}
apply plugin: "eclipse"