-
Notifications
You must be signed in to change notification settings - Fork 2
/
build.gradle
142 lines (120 loc) · 4.34 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
133
134
135
136
137
138
139
140
plugins {
id 'org.springframework.boot' version '2.6.0'
id 'io.spring.dependency-management' version '1.0.11.RELEASE'
id 'java'
}
version = '0.0.1-SNAPSHOT'
ext {
junitJupiterVersion = '5.8.1'
lombokVersion = '1.18.22'
clickhouseVersion = '0.3.1-patch'
mybatisVersion = '2.2.0'
mybatisPlusVersion = '3.4.3.4'
dynamicDatasourceVersion = '3.5.0'
}
allprojects {
group = 'cloud.aispring'
sourceCompatibility = '17'
repositories {
maven { url 'https://maven.aliyun.com/repository/public/' }
maven { url 'https://maven.aliyun.com/repository/google/' }
maven { url 'https://maven.aliyun.com/repository/jcenter/' }
mavenCentral()
mavenLocal()
}
apply plugin: "io.spring.dependency-management"
apply plugin: "org.springframework.boot"
apply plugin: "java"
dependencyManagement {
resolutionStrategy {
cacheChangingModulesFor 0, 'seconds'
}
applyMavenExclusions = false
generatedPomCustomization {
enabled = false
}
}
}
subprojects { subproject ->
dependencies {
implementation "org.mybatis.spring.boot:mybatis-spring-boot-starter:$mybatisVersion"
implementation "com.baomidou:mybatis-plus-boot-starter:$mybatisPlusVersion"
implementation "com.baomidou:dynamic-datasource-spring-boot-starter:$dynamicDatasourceVersion"
runtimeOnly 'mysql:mysql-connector-java'
implementation "ru.yandex.clickhouse:clickhouse-jdbc:$clickhouseVersion"
testImplementation 'org.springframework.boot:spring-boot-starter-test'
implementation "org.projectlombok:lombok:$lombokVersion"
annotationProcessor "org.projectlombok:lombok:$lombokVersion"
testImplementation "org.junit.jupiter:junit-jupiter-api:$junitJupiterVersion"
testRuntimeOnly "org.junit.jupiter:junit-jupiter-engine:$junitJupiterVersion"
}
test {
useJUnitPlatform()
}
}
project('mybatis-plus-clickhouse') {
description = 'Mybatis-Plus ClickHouse Update and Delete'
version = '3.0'
apply plugin: "signing"
apply plugin: "maven-publish"
java {
withJavadocJar()
withSourcesJar()
}
publishing {
publications {
mavenJava(MavenPublication) {
from components.java
pom {
name = 'mybatis-plus-clickhouse'
description = 'Mybatis-Plus ClickHouse Update and Delete'
url = 'https://www.aispring.cloud'
licenses {
license {
name = 'The Apache License, Version 2.0'
url = 'http://www.apache.org/licenses/LICENSE-2.0.txt'
}
}
developers {
developer {
id = 'aispring'
name = 'aispring'
email = '[email protected]'
}
}
scm {
url = 'https://github.com/aispringli/mybatis-plus-clickhouse'
}
}
}
}
repositories {
maven {
def releasesRepoUrl = "https://oss.sonatype.org/service/local/staging/deploy/maven2"
def snapshotsRepoUrl = "https://oss.sonatype.org/content/repositories/snapshots"
// 如果version以SNAPSHOT结尾就会上传到快照仓库,如果不是就上传到release仓库
url = version.endsWith('SNAPSHOT') ? snapshotsRepoUrl : releasesRepoUrl
credentials {
username = "${NEXUS_USERNAME}"
password = "${NEXUS_PASSWORD}"
}
}
}
}
javadoc {
if (JavaVersion.current().isJava9Compatible()) {
options.addBooleanOption('html5', true)
}
}
signing {
sign publishing.publications.mavenJava
}
}
project('mybatis-plus-clickhouse-test') {
description = 'Mybatis-Plus ClickHouse Test'
dependencies {
implementation 'org.springframework.boot:spring-boot-starter-jdbc'
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation project(':mybatis-plus-clickhouse')
}
}