Skip to content

Commit 9c6e5b6

Browse files
fix gradle warnings
1 parent 2f4df7a commit 9c6e5b6

File tree

4 files changed

+92
-98
lines changed

4 files changed

+92
-98
lines changed

buildSrc/src/main/kotlin/ktorm.base.gradle.kts

+5-11
Original file line numberDiff line numberDiff line change
@@ -36,24 +36,18 @@ tasks {
3636
compileKotlin {
3737
dependsOn(codegen)
3838

39-
kotlinOptions {
40-
jvmTarget = "1.8"
39+
compilerOptions {
40+
jvmTarget = org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_1_8
4141
allWarningsAsErrors = true
4242
freeCompilerArgs = listOf("-Xexplicit-api=strict")
4343
}
4444
}
4545

46-
compileTestKotlin {
47-
kotlinOptions {
48-
jvmTarget = "1.8"
49-
}
50-
}
51-
5246
jacocoTestReport {
5347
reports {
54-
csv.required.set(true)
55-
xml.required.set(true)
56-
html.required.set(true)
48+
csv.required = true
49+
xml.required = true
50+
html.required = true
5751
}
5852
}
5953
}

buildSrc/src/main/kotlin/ktorm.dokka.gradle.kts

+5-5
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ subprojects {
1919
dependsOn("codegen")
2020

2121
dokkaSourceSets.named("main") {
22-
suppressGeneratedFiles.set(false)
22+
suppressGeneratedFiles = false
2323
}
2424
}
2525

@@ -34,11 +34,11 @@ subprojects {
3434
}
3535

3636
dokkaSourceSets.named("main") {
37-
suppressGeneratedFiles.set(false)
37+
suppressGeneratedFiles = false
3838
sourceLink {
39-
localDirectory.set(file("src/main/kotlin"))
40-
remoteUrl.set(java.net.URL("https://github.com/kotlin-orm/ktorm/blob/master/${project.name}/src/main/kotlin"))
41-
remoteLineSuffix.set("#L")
39+
localDirectory = file("src/main/kotlin")
40+
remoteUrl = uri("https://github.com/kotlin-orm/ktorm/blob/master/${project.name}/src/main/kotlin").toURL()
41+
remoteLineSuffix = "#L"
4242
}
4343
}
4444
}

buildSrc/src/main/kotlin/ktorm.publish.gradle.kts

+81-81
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,13 @@ plugins {
99
val jarSources by tasks.registering(Jar::class) {
1010
dependsOn("codegen")
1111
from(sourceSets.main.map { it.allSource })
12-
archiveClassifier.set("sources")
12+
archiveClassifier = "sources"
1313
}
1414

1515
val jarJavadoc by tasks.registering(Jar::class) {
1616
dependsOn(tasks.dokkaJavadoc)
1717
from(tasks.dokkaJavadoc.flatMap { it.outputDirectory })
18-
archiveClassifier.set("javadoc")
18+
archiveClassifier = "javadoc"
1919
}
2020

2121
publishing {
@@ -30,139 +30,139 @@ publishing {
3030
version = project.version.toString()
3131

3232
pom {
33-
name.set("${project.group}:${project.name}")
34-
description.set("A lightweight ORM Framework for Kotlin with strong typed SQL DSL and sequence APIs.")
35-
url.set("https://www.ktorm.org")
33+
name = "${project.group}:${project.name}"
34+
description = "A lightweight ORM Framework for Kotlin with strong typed SQL DSL and sequence APIs."
35+
url = "https://www.ktorm.org"
3636
licenses {
3737
license {
38-
name.set("The Apache Software License, Version 2.0")
39-
url.set("http://www.apache.org/licenses/LICENSE-2.0.txt")
38+
name = "The Apache Software License, Version 2.0"
39+
url = "http://www.apache.org/licenses/LICENSE-2.0.txt"
4040
}
4141
}
4242
scm {
43-
url.set("https://github.com/kotlin-orm/ktorm")
44-
connection.set("scm:git:https://github.com/kotlin-orm/ktorm.git")
45-
developerConnection.set("scm:git:ssh://[email protected]/kotlin-orm/ktorm.git")
43+
url = "https://github.com/kotlin-orm/ktorm"
44+
connection = "scm:git:https://github.com/kotlin-orm/ktorm.git"
45+
developerConnection = "scm:git:ssh://[email protected]/kotlin-orm/ktorm.git"
4646
}
4747
developers {
4848
developer {
49-
id.set("vincentlauvlwj")
50-
name.set("vince")
51-
email.set("[email protected]")
49+
id = "vincentlauvlwj"
50+
name = "vince"
51+
5252
}
5353
developer {
54-
id.set("waluo")
55-
name.set("waluo")
56-
email.set("[email protected]")
54+
id = "waluo"
55+
name = "waluo"
56+
5757
}
5858
developer {
59-
id.set("clydebarrow")
60-
name.set("Clyde")
61-
email.set("[email protected]")
59+
id = "clydebarrow"
60+
name = "Clyde"
61+
6262
}
6363
developer {
64-
id.set("Ray-Eldath")
65-
name.set("Ray Eldath")
66-
email.set("[email protected]")
64+
id = "Ray-Eldath"
65+
name = "Ray Eldath"
66+
6767
}
6868
developer {
69-
id.set("hangingman")
70-
name.set("hiroyuki.nagata")
71-
email.set("[email protected]")
69+
id = "hangingman"
70+
name = "hiroyuki.nagata"
71+
7272
}
7373
developer {
74-
id.set("onXoot")
75-
name.set("beetlerx")
76-
email.set("[email protected]")
74+
id = "onXoot"
75+
name = "beetlerx"
76+
7777
}
7878
developer {
79-
id.set("arustleund")
80-
name.set("Andrew Rustleund")
81-
email.set("[email protected]")
79+
id = "arustleund"
80+
name = "Andrew Rustleund"
81+
8282
}
8383
developer {
84-
id.set("afezeria")
85-
name.set("afezeria")
86-
email.set("[email protected]")
84+
id = "afezeria"
85+
name = "afezeria"
86+
8787
}
8888
developer {
89-
id.set("scorsi")
90-
name.set("Sylvain Corsini")
91-
email.set("[email protected]")
89+
id = "scorsi"
90+
name = "Sylvain Corsini"
91+
9292
}
9393
developer {
94-
id.set("lyndsysimon")
95-
name.set("Lyndsy Simon")
96-
email.set("[email protected]")
94+
id = "lyndsysimon"
95+
name = "Lyndsy Simon"
96+
9797
}
9898
developer {
99-
id.set("antonydenyer")
100-
name.set("Antony Denyer")
101-
email.set("[email protected]")
99+
id = "antonydenyer"
100+
name = "Antony Denyer"
101+
102102
}
103103
developer {
104-
id.set("mik629")
105-
name.set("Mikhail Erkhov")
106-
email.set("[email protected]")
104+
id = "mik629"
105+
name = "Mikhail Erkhov"
106+
107107
}
108108
developer {
109-
id.set("sinzed")
110-
name.set("Saeed Zahedi")
111-
email.set("[email protected]")
109+
id = "sinzed"
110+
name = "Saeed Zahedi"
111+
112112
}
113113
developer {
114-
id.set("smn-dv")
115-
name.set("Simon Schoof")
116-
email.set("[email protected]")
114+
id = "smn-dv"
115+
name = "Simon Schoof"
116+
117117
}
118118
developer {
119-
id.set("pedrod")
120-
name.set("Pedro Domingues")
121-
email.set("[email protected]")
119+
id = "pedrod"
120+
name = "Pedro Domingues"
121+
122122
}
123123
developer {
124-
id.set("efenderbosch")
125-
name.set("Eric Fenderbosch")
126-
email.set("[email protected]")
124+
id = "efenderbosch"
125+
name = "Eric Fenderbosch"
126+
127127
}
128128
developer {
129-
id.set("kocproz")
130-
name.set("Kacper Stasiuk")
131-
email.set("[email protected]")
129+
id = "kocproz"
130+
name = "Kacper Stasiuk"
131+
132132
}
133133
developer {
134-
id.set("2938137849")
135-
name.set("ccr")
136-
email.set("[email protected]")
134+
id = "2938137849"
135+
name = "ccr"
136+
137137
}
138138
developer {
139-
id.set("zuisong")
140-
name.set("zuisong")
141-
email.set("[email protected]")
139+
id = "zuisong"
140+
name = "zuisong"
141+
142142
}
143143
developer {
144-
id.set("svenallers")
145-
name.set("Sven Allers")
146-
email.set("[email protected]")
144+
id = "svenallers"
145+
name = "Sven Allers"
146+
147147
}
148148
developer {
149-
id.set("lookup-cat")
150-
name.set("夜里的向日葵")
151-
email.set("[email protected]")
149+
id = "lookup-cat"
150+
name = "夜里的向日葵"
151+
152152
}
153153
developer {
154-
id.set("michaelfyc")
155-
name.set("michaelfyc")
156-
email.set("[email protected]")
154+
id = "michaelfyc"
155+
name = "michaelfyc"
156+
157157
}
158158
developer {
159-
id.set("brohacz")
160-
name.set("Michal Brosig")
159+
id = "brohacz"
160+
name = "Michal Brosig"
161161
}
162162
developer {
163-
id.set("hc224")
164-
name.set("hc224")
165-
email.set("[email protected]")
163+
id = "hc224"
164+
name = "hc224"
165+
166166
}
167167
}
168168
}

ktorm-core/ktorm-core.gradle.kts

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ val testOutput by configurations.creating {
2121
val testJar by tasks.registering(Jar::class) {
2222
dependsOn(tasks.testClasses)
2323
from(sourceSets.test.map { it.output })
24-
archiveClassifier.set("test")
24+
archiveClassifier = "test"
2525
}
2626

2727
artifacts {

0 commit comments

Comments
 (0)