-
Notifications
You must be signed in to change notification settings - Fork 25
/
Copy pathbuild.gradle
132 lines (112 loc) · 3.55 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
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
buildscript {
ext.kotlin_version = '1.8.10'
ext.exodus_version = '3.0.86'
ext.dokka_version = '1.7.20'
ext.log4j_version = '2.17.1'
ext.google_truth_version = '1.1.3'
ext.junit_version = '4.13.2'
dependencies {
classpath "org.jetbrains.dokka:dokka-gradle-plugin:${dokka_version}"
}
}
plugins {
id 'com.github.hierynomus.license' version '0.16.1'
id 'org.jetbrains.kotlin.jvm' version "$kotlin_version"
id 'io.codearte.nexus-staging' version '0.21.1'
id 'de.marcphilipp.nexus-publish' version '0.4.0' apply false
id 'idea'
}
idea {
project {
jdkName = '11'
vcs = 'Git'
}
module {
downloadSources = true
}
}
allprojects {
group = 'org.jetbrains.xodus'
version = '3.0.' + ((project.hasProperty("teamcity")) ? project.teamcity["build.number"] : 'dev')
repositories {
mavenCentral()
maven { url 'https://packages.jetbrains.team/maven/p/xodus/xodus-daily' }
// necessary for dokka 1.4.30
maven { url "https://maven.pkg.jetbrains.space/public/p/kotlinx-html/maven" }
}
java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(11))
}
}
}
subprojects {
apply plugin: 'java'
apply plugin: 'kotlin'
apply plugin: 'license'
apply plugin: 'org.jetbrains.dokka'
java {
toolchain {
languageVersion.set(JavaLanguageVersion.of(11))
}
}
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
implementation 'io.github.microutils:kotlin-logging:1.5.4'
testImplementation "junit:junit:$junit_version"
testImplementation "org.apache.logging.log4j:log4j-1.2-api:$log4j_version"
testImplementation "org.apache.logging.log4j:log4j-api:$log4j_version"
testImplementation "org.apache.logging.log4j:log4j-core:$log4j_version"
testImplementation "org.apache.logging.log4j:log4j-slf4j-impl:$log4j_version"
}
license {
header rootProject.file('license/copyright.ftl')
strictCheck true
ext.inceptionYear = 2006
ext.year = Calendar.getInstance().get(Calendar.YEAR)
ext.owner = 'JetBrains s.r.o.'
include "**/*.kt"
include "**/*.java"
mapping {
kt = 'JAVADOC_STYLE'
}
}
tasks.withType(compileKotlin.class).all {
kotlinOptions {
jvmTarget = "11"
apiVersion = "1.8"
languageVersion = "1.8"
}
}
test {
minHeapSize = '512m'
maxHeapSize = '512m'
systemProperty 'exodus.tests.buildDirectory', project.buildDir
testLogging {
showStandardStreams = true
exceptionFormat = 'full'
}
outputs.upToDateWhen { false }
}
dokkaJavadoc {
dokkaSourceSets {
configureEach {
reportUndocumented.set(false)
}
}
}
tasks.register('sourceJar', Jar) {
archiveClassifier = 'sources'
duplicatesStrategy 'exclude'
includeEmptyDirs false
from project.sourceSets.main.java
from project.sourceSets.main.kotlin
}
// this is a stub javadoc until we investigate and fix the following docklet error somehow:
// java.lang.ClassCastException: com.sun.tools.javac.code.Type$AnnotatedType cannot be cast to com.sun.tools.javac.code.Type$ClassType
task javadocJar(type: Jar) {
archiveClassifier = 'javadoc'
from "${rootProject.projectDir}/README.MD"
}
}
apply from: 'publishing.gradle'