-
Notifications
You must be signed in to change notification settings - Fork 12
/
build.gradle
112 lines (94 loc) · 3.08 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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
/**
* Copyright (c) Dell Inc., or its subsidiaries. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
*/
import com.github.jengelman.gradle.plugins.shadow.tasks.ConfigureShadowRelocation
buildscript {
repositories {
mavenCentral()
}
}
plugins {
id 'com.github.johnrengelman.shadow' version '8.0.0'
id 'org.ajoberstar.grgit' version '3.1.1'
}
apply from: "$rootDir/gradle/version.gradle"
allprojects {
apply plugin: 'jacoco'
}
subprojects {
apply plugin: 'java-library'
apply plugin: 'com.github.johnrengelman.shadow'
repositories {
mavenCentral()
maven {
url "https://maven.pkg.github.com/pravega/pravega"
credentials {
username = "pravega-public"
password = "\u0067\u0068\u0070\u005F\u0048\u0034\u0046\u0079\u0047\u005A\u0031\u006B\u0056\u0030\u0051\u0070\u006B\u0079\u0058\u006D\u0035\u0063\u0034\u0055\u0033\u006E\u0032\u0065\u0078\u0039\u0032\u0046\u006E\u0071\u0033\u0053\u0046\u0076\u005A\u0049"
}
}
}
group "io.pravega"
sourceCompatibility = 11
// Creates a Jar with Java source files
task sourceJar(type: Jar) {
from sourceSets.main.allJava
archiveClassifier = 'sources'
}
task javadocJar(type: Jar) {
archiveClassifier = 'javadoc'
from javadoc.destinationDir
}
dependencies {
implementation platform("org.keycloak.bom:keycloak-adapter-bom:${keycloakVersion}")
}
jacocoTestReport {
reports {
xml.required = true
html.required = false
}
}
check.dependsOn jacocoTestReport
}
project('client') {
apply from: "$rootDir/gradle/maven-publish.gradle"
tasks.withType(PublishToMavenRepository) {
doFirst {
println("Publishing ${publication.groupId}:${publication.artifactId}:${publication.version} to ${repository.url}")
}
}
configurations {
implementation {
exclude group: 'org.projectlombok', module: 'lombok'
}
testImplementation {
extendsFrom compileOnly
}
}
dependencies {
compileOnly "org.slf4j:slf4j-api:${slf4jVersion}"
compileOnly "io.pravega:pravega-shared-security:${pravegaVersion}"
implementation "org.keycloak:keycloak-authz-client"
implementation "com.google.guava:guava:${guavaVersion}"
testImplementation "org.keycloak:keycloak-adapter-core"
testImplementation "junit:junit:${junitVersion}"
testImplementation "org.mockito:mockito-core:${mockitoVersion}"
}
task relocateShadowJar(type: ConfigureShadowRelocation) {
target = tasks.shadowJar
prefix = "io.pravega.keycloak"
}
shadowJar {
mergeServiceFiles()
}
jar.enabled = false
tasks.shadowJar.dependsOn tasks.relocateShadowJar
tasks.build.dependsOn tasks.shadowJar
}