Skip to content

Commit c17d40e

Browse files
committed
build: update to gradle8
1 parent b078626 commit c17d40e

File tree

5 files changed

+22
-29
lines changed

5 files changed

+22
-29
lines changed

buildSrc/src/main/kotlin/com.expediagroup.graphql.conventions.gradle.kts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,6 @@ tasks {
5353
attributes["Implementation-Title"] = project.name
5454
attributes["Implementation-Version"] = project.version
5555
}
56-
57-
// NOTE: in order to run gradle and maven plugin integration tests we need to have our build artifacts available in local repo
58-
finalizedBy("publishToMavenLocal")
5956
}
6057

6158
// published sources and javadoc artifacts

gradle/wrapper/gradle-wrapper.jar

34 Bytes
Binary file not shown.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-7.6-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.0.2-bin.zip
44
networkTimeout=10000
55
zipStoreBase=GRADLE_USER_HOME
66
zipStorePath=wrapper/dists

gradlew

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -144,15 +144,15 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
144144
case $MAX_FD in #(
145145
max*)
146146
# In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
147-
# shellcheck disable=SC3045
147+
# shellcheck disable=SC3045
148148
MAX_FD=$( ulimit -H -n ) ||
149149
warn "Could not query maximum file descriptor limit"
150150
esac
151151
case $MAX_FD in #(
152152
'' | soft) :;; #(
153153
*)
154154
# In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
155-
# shellcheck disable=SC3045
155+
# shellcheck disable=SC3045
156156
ulimit -n "$MAX_FD" ||
157157
warn "Could not set maximum file descriptor limit to $MAX_FD"
158158
esac

plugins/graphql-kotlin-gradle-plugin/build.gradle.kts

Lines changed: 19 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -42,38 +42,34 @@ pluginBundle {
4242
tags = listOf("graphql", "kotlin", "graphql-client", "schema-generator", "sdl")
4343
}
4444

45-
sourceSets {
46-
main {
47-
java {
48-
srcDir("$buildDir/generated/src")
49-
}
50-
}
51-
}
52-
53-
tasks {
54-
val generateDefaultVersion by registering {
55-
val fileName = "PluginVersion.kt"
56-
val defaultVersionFile = File("$buildDir/generated/src/com/expediagroup/graphql/plugin/gradle", fileName)
45+
val generateDefaultVersion by tasks.registering {
46+
val fileName = "PluginVersion.kt"
47+
val defaultVersionFile = File("$buildDir/generated/src/com/expediagroup/graphql/plugin/gradle", fileName)
5748

58-
inputs.property(fileName, project.version)
59-
outputs.file(defaultVersionFile)
49+
inputs.property(fileName, project.version)
50+
outputs.file(defaultVersionFile.parent)
6051

61-
doFirst {
62-
defaultVersionFile.parentFile.mkdirs()
63-
defaultVersionFile.writeText(
64-
"""
52+
doFirst {
53+
defaultVersionFile.parentFile.mkdirs()
54+
defaultVersionFile.writeText(
55+
"""
6556
package com.expediagroup.graphql.plugin.gradle
6657
internal const val DEFAULT_PLUGIN_VERSION = "${project.version}"
6758
68-
""".trimIndent()
69-
)
70-
}
59+
""".trimIndent()
60+
)
7161
}
62+
}
7263

73-
compileKotlin {
74-
dependsOn(generateDefaultVersion)
64+
sourceSets {
65+
main {
66+
java {
67+
srcDir(generateDefaultVersion)
68+
}
7569
}
70+
}
7671

72+
tasks {
7773
publishPlugins {
7874
doFirst {
7975
System.setProperty("gradle.publish.key", System.getenv("PLUGIN_PORTAL_KEY"))

0 commit comments

Comments
 (0)