Skip to content

Commit 056b95f

Browse files
committed
Upgrade
- Java tool chain version to 17 - Gradle to 8.14.1 - Nexus plugin fix Signed-off-by: Gopal S Akshintala <[email protected]>
1 parent 794cdb7 commit 056b95f

File tree

8 files changed

+43
-13
lines changed

8 files changed

+43
-13
lines changed

.idea/kotlinc.xml

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

CONTRIBUTING.adoc

Lines changed: 26 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,11 +85,33 @@ It may be slow for the first run, but later runs should be faster.
8585
8686
== Manual publishing
8787
88-
In link:build.gradle.kts[], follow the <<_versioning_strategy,Versioning Strategy>>
88+
=== Gradle Nexus Publish Plugin
8989
90-
* Follow the <<_versioning_strategy,Versioning Strategy>> to increment version link:buildSrc/{sourcedir}/Config.kt[here]
91-
** For SNAPSHOT releases, add a `-SNAPSHOT` at the end of version number
92-
* Run this command to publish it to Nexus:
90+
We use link:https://github.com/gradle-nexus/publish-plugin#publishing-to-maven-central-via-sonatype-central[Gradle Nexus Publish Plugin]
91+
to publish to Maven Central. Follow the usage instructions to set up Sonatype credentials and add them to your `~/.gradle/gradle.properties`.
92+
93+
[source,bash]
94+
----
95+
sonatypeUsername=<your-username>
96+
sonatypePassword=<your-password>
97+
----
98+
99+
=== Versioning Strategy
100+
101+
====
102+
<A>.<B>.<C>
103+
====
104+
105+
* A = Broke something on purpose (Breaking API change)
106+
* B = Profit (Feature / Improvement)
107+
* C = Broke something by accident (Bug)
108+
109+
Follow the Versioning Strategy to increment version link:buildSrc/{sourcedir}/Config.kt[here].
110+
For SNAPSHOT releases, add a `-SNAPSHOT` at the end of version number
111+
112+
=== Publish
113+
114+
Run this command to publish it to Nexus:
93115
94116
[source,bash]
95117
----

build.gradle.kts

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,4 +78,12 @@ afterEvaluate {
7878
}
7979
}
8080

81-
nexusPublishing { this.repositories { sonatype { stagingProfileId = STAGING_PROFILE_ID } } }
81+
nexusPublishing {
82+
this.repositories {
83+
sonatype {
84+
stagingProfileId = STAGING_PROFILE_ID
85+
nexusUrl = uri("https://ossrh-staging-api.central.sonatype.com/service/local/")
86+
snapshotRepositoryUrl = uri("https://central.sonatype.com/repository/maven-snapshots/")
87+
}
88+
}
89+
}

buildSrc/src/main/kotlin/vador.publishing-conventions.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ repositories { mavenCentral() }
2424
java {
2525
withJavadocJar()
2626
withSourcesJar()
27-
toolchain { languageVersion.set(JavaLanguageVersion.of(11)) }
27+
toolchain { languageVersion.set(JavaLanguageVersion.of(17)) }
2828
}
2929

3030
publishing {

gradle/wrapper/gradle-wrapper.jar

181 Bytes
Binary file not shown.

gradle/wrapper/gradle-wrapper.properties

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-8.12.1-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.1-bin.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

gradlew

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ case "$( uname )" in #(
114114
NONSTOP* ) nonstop=true ;;
115115
esac
116116

117-
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
117+
CLASSPATH="\\\"\\\""
118118

119119

120120
# Determine the Java command to use to start the JVM.
@@ -205,15 +205,15 @@ fi
205205
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
206206

207207
# Collect all arguments for the java command:
208-
# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
208+
# * DEFAULT_JVM_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
209209
# and any embedded shellness will be escaped.
210210
# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be
211211
# treated as '${Hostname}' itself on the command line.
212212

213213
set -- \
214214
"-Dorg.gradle.appname=$APP_BASE_NAME" \
215215
-classpath "$CLASSPATH" \
216-
org.gradle.wrapper.GradleWrapperMain \
216+
-jar "$APP_HOME/gradle/wrapper/gradle-wrapper.jar" \
217217
"$@"
218218

219219
# Stop when "xargs" is not available.

gradlew.bat

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,11 +70,11 @@ goto fail
7070
:execute
7171
@rem Setup the command line
7272

73-
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
73+
set CLASSPATH=
7474

7575

7676
@rem Execute Gradle
77-
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
77+
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" -jar "%APP_HOME%\gradle\wrapper\gradle-wrapper.jar" %*
7878

7979
:end
8080
@rem End local scope for the variables with windows NT shell

0 commit comments

Comments
 (0)