forked from palantir/auth-tokens
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
81 lines (70 loc) · 3.04 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
buildscript {
repositories {
jcenter()
maven { url "http://palantir.bintray.com/releases" }
maven {
url 'https://plugins.gradle.org/m2/'
}
}
dependencies {
classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.4'
classpath 'com.netflix.nebula:gradle-dependency-lock-plugin:4.9.3'
classpath 'com.netflix.nebula:gradle-info-plugin:3.0.3'
classpath 'com.netflix.nebula:nebula-dependency-recommender:4.2.0'
classpath 'com.netflix.nebula:nebula-publishing-plugin:4.10.0'
classpath 'gradle.plugin.com.palantir.gradle.gitversion:gradle-git-version:0.4.2'
classpath "com.palantir.baseline:gradle-baseline-java:${baselineVersion}"
classpath 'gradle.plugin.org.inferred:gradle-processors:1.2.2'
classpath 'com.netflix.nebula:nebula-bintray-plugin:3.3.4'
classpath 'gradle.plugin.com.palantir.configurationresolver:gradle-configuration-resolver-plugin:0.2.0'
}
}
apply plugin: 'com.palantir.baseline-config'
apply plugin: 'com.palantir.baseline-idea'
apply plugin: 'com.palantir.git-version'
dependencies {
baseline "com.palantir.baseline:gradle-baseline-java-config:${baselineVersion}@zip"
}
allprojects {
apply plugin: 'com.palantir.configuration-resolver'
apply plugin: 'nebula.dependency-recommender'
dependencyRecommendations {
strategy OverrideTransitives
propertiesFile file: project.rootProject.file('versions.props')
}
group 'com.palantir.tokens'
repositories {
jcenter()
maven { url "http://palantir.bintray.com/releases" }
}
version gitVersion()
}
subprojects {
apply plugin: 'java'
apply plugin: 'com.palantir.baseline-checkstyle'
apply plugin: 'com.palantir.baseline-eclipse'
apply plugin: 'com.palantir.baseline-error-prone'
apply plugin: 'com.palantir.baseline-idea'
apply plugin: 'org.inferred.processors'
sourceCompatibility = 1.8
apply plugin: 'nebula.dependency-lock'
dependencyLock {
includeTransitives = true
lockFile = 'versions.lock'
configurationNames = ['runtime', 'compileClasspath']
}
task verifyDependencyLocksAreCurrent << {
def expectedDependencies = tasks.saveLock.getOutputLock()
def actualDependencies = tasks.saveLock.getGeneratedLock()
def digester = java.security.MessageDigest.getInstance('SHA')
logger.info("Verifying integrity of dependency locks: {} vs {}", expectedDependencies, actualDependencies)
if (digester.digest(expectedDependencies.bytes) != digester.digest(actualDependencies.bytes)) {
throw new GradleException("The dependencies of project " + project.name + " do not match the expected "
+ "dependencies recorded in " + expectedDependencies + ". "
+ "Run `./gradlew generateLock saveLock` and commit the updated version.lock files")
}
}
if (System.env.CIRCLE_TEST_REPORTS) {
test.reports.junitXml.destination = new File(System.env.CIRCLE_TEST_REPORTS, it.getName())
}
}