I'm trying to publish my JAR to maven Central I followed every step given here. The last step mentioned there is
gradle uploadArchives
Which worked, and said successfully uploaded. but when I go to release site, I don't see my jar there to release. What am I missing?
gradle uploadArchives
is successful doesn't always mean your artifact will be available for release (Sonatype calls them staging repository).
For my case my Artifact version was 1.0.0-Snapshot
. as I had SnapShot
keyword in my version number it was actually released to SnapShot repository . When I removed snapshot
word from my version and redeployed it was available in staging and i was able to release it to mvn central
signing.keyId=C4B4D83B #(gpg --list-keys , last 8 digit )
signing.password=z_*** #(password that you used to sign keys)
signing.secretKeyRingFile=/Users/<ur machine username>/.gnupg/secring.gpg
ossrhUsername=sapy
ossrhPassword=<ossrhpassword from google key chain>
gradle uploadArchives
close
. It takes some time to close.Release
button. This will move the components into the release repository of OSSRH where it will be synced to the Central Repository.