You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: www/PublishingToMavenCentral.md
+15-14Lines changed: 15 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,32 +4,33 @@ Publishing JNA to Maven Central
4
4
One Time
5
5
--------
6
6
7
-
* Create an account in the [sonatype jira](https://issues.sonatype.org/secure/Signup!default.jspa)
7
+
* Create an account for the maven central repository
8
+
([Register to Publish Via the Central Portal](https://central.sonatype.org/register/central-portal/))
8
9
* Get the account enabled for publishing to the net.java.dev.jna groupId
9
10
(contact an existing uploader for this)
10
11
* Set up your gpg keys as described [here](http://central.sonatype.org/pages/working-with-pgp-signatures.html). Make sure you distribute your public key.
11
12
* Make sure you have a settings.xml file (in directory: ${user.home}/.m2/).
12
-
For example (Replace *myossrhuser* and *myossrhpwd* with the account credentials):
13
+
For example (Replace *central-user* and *central-password* with the
14
+
credentials you can create via "View Account" -> "Generate User Token"):
13
15
```xml
14
16
<settings>
15
17
...
16
18
<servers>
17
19
...
18
20
<server>
19
-
<id>oss.sonatype.org</id>
20
-
<username>myossrhuser</username>
21
-
<password>myossrhpwd</password>
21
+
<id>sonatype-central-portal-snapshots</id>
22
+
<username>central-user</username>
23
+
<password>central-password</password>
22
24
</server>
23
25
...
24
26
</servers>
25
27
...
26
28
<settings>
27
29
```
28
-
29
-
The binaries are hosted in the Sonatype OSSRH (OSS Repository Hosting) system,
30
-
and mirrored from there to maven central.
31
30
32
-
See [OSSRH Guide](http://central.sonatype.org/pages/ossrh-guide.html) for more info.
31
+
These settings are only used for uploading SNAPSHOTs. See:
see: [https://oss.sonatype.org/content/repositories/snapshots/net/java/dev/jna/](https://oss.sonatype.org/content/repositories/snapshots/net/java/dev/jna/) for the various jars.
To publish a development SNAPSHOT do the following:
47
46
@@ -58,5 +57,7 @@ Publish Release
58
57
* Verify the <version> tags in [pom-jna.xml](https://github.com/java-native-access/jna/blob/master/pom-jna.xml)
59
58
and [pom-jna-platform.xml](https://github.com/java-native-access/jna/blob/master/pom-jna-platform.xml)
60
59
match the version (jna.version) in [build.xml](https://github.com/java-native-access/jna/blob/master/build.xml).
61
-
* Run `ant -Dmaven-release=true stage`. This uploads current checkout to [oss.sonatype.org](https://oss.sonatype.org).
62
-
* Follow steps from [Releasing the Deployment](http://central.sonatype.org/pages/releasing-the-deployment.html).
60
+
* Run `ant -Dmaven-release=true stage`. This builds JNA and creates a ZIP file `build/maven-artifacts.zip`.
61
+
That file can be used to deploy to maven central using the manual
62
+
[Publishing By Uploading a Bundle](https://central.sonatype.org/publish/publish-portal-upload/)
0 commit comments