Attempt at central publishing 2
This commit is contained in:
parent
e85017fded
commit
d21a4be023
2 changed files with 19 additions and 2 deletions
17
README.md
17
README.md
|
|
@ -130,6 +130,23 @@ class Example {
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Publishing to Maven Central
|
||||||
|
|
||||||
|
EntityLib uses the new Maven Central publishing system via the Central Portal (replacing the deprecated OSSRH). To publish, set up the following GitHub secrets:
|
||||||
|
|
||||||
|
- `OSSRH_USERNAME`: Your Central Portal username (usually your email).
|
||||||
|
- `OSSRH_PASSWORD`: Your publishing token from the Central Portal.
|
||||||
|
- `GPG_PRIVATE_KEY`: Your GPG private key (for signing artifacts).
|
||||||
|
- `GPG_PASSPHRASE`: The passphrase for your GPG key.
|
||||||
|
|
||||||
|
### Setting Up Central Portal Credentials
|
||||||
|
1. Go to [Central Portal](https://central.sonatype.com/) and log in with your GitHub account.
|
||||||
|
2. Create a namespace for your group ID (`io.github.tofaa2`).
|
||||||
|
3. Generate a publishing token from the "Account Settings" > "Publishing Tokens".
|
||||||
|
4. Use your email as the username and the token as the password.
|
||||||
|
|
||||||
|
Snapshots are automatically published on pushes to the `master` branch. Stable releases are published when a GitHub release is created.
|
||||||
|
|
||||||
### TODO:
|
### TODO:
|
||||||
Once this list is complete, i will release a stable version of the library.
|
Once this list is complete, i will release a stable version of the library.
|
||||||
- [ ] Implement checks for each EntityMeta to make sure the version specific data is correct.
|
- [ ] Implement checks for each EntityMeta to make sure the version specific data is correct.
|
||||||
|
|
|
||||||
|
|
@ -86,8 +86,8 @@ publishing {
|
||||||
maven {
|
maven {
|
||||||
url = uri("https://central.sonatype.com/api/v1/publisher/upload")
|
url = uri("https://central.sonatype.com/api/v1/publisher/upload")
|
||||||
credentials {
|
credentials {
|
||||||
username = System.getenv("CENTRAL_PORTAL_USERNAME")
|
username = System.getenv("OSSRH_USERNAME")
|
||||||
password = System.getenv("CENTRAL_PORTAL_TOKEN")
|
password = System.getenv("OSSRH_PASSWORD")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue