I work on some Kotlin/Gradle/Sonatype open source ...
# build-tools
g
I work on some Kotlin/Gradle/Sonatype open source projects using
build.gradle.kts
files. I've been manually signing in to Sonatype in order to "close" and "release" the uploaded artifacts for a few years. I never had to do this with my maven projects. I think it is not necessary any more with gradle. Is there a build.gradle.kts file you would suggest I copy from somewhere? For reference, here is one project's build file that I have to then close and release manually through the web UI: https://github.com/GlenKPeterson/Indented/blob/master/build.gradle.kts
m
You're most likely looking for this: https://github.com/gradle-nexus/publish-plugin
🙏🏻 1
🙇🏻 1
👀 1
Note that oss.sonatype.org is super slow these days, partly due to all the log4j mitigations so closing a repository automatically very often ends up timing out. In these cases, having the option to do things manually comes handy
g
Is there a better place to publish?
m
Not really 🙃
Well, actually, there is!
s01.oss.sonatype.org is much faster
g
So...
nexusUrl.set(uri("<https://s01.oss.sonatype.org/staging>"))
?
m
You'll need to ask Sonatype to migrate your groupId first (with a Jira ticket)
If you're happy with oss.sonatype.org, feel free to ignore this though.
g
Sweet! That worked (with the old Sonatype URL). Thank you!
👍 1