Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revised the Maven release documentation and made some fixes #1951

Merged
merged 1 commit into from
Jul 15, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 18 additions & 9 deletions docs/antora/modules/ROOT/pages/Common_Project_Layouts.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -313,8 +313,12 @@ object foo extends ScalaModule with PublishModule {
You can make a module publishable by extending `PublishModule`.

`PublishModule` then needs you to define a `publishVersion` and `pomSettings`.
The `artifactName` defaults to the name of your module (in this case `foo`) but
can be overridden. The `organization` is defined in `pomSettings`.
The `artifactName` defaults to the name of your module (in this case `foo`) but can be overridden.
The `organization` is defined in `pomSettings`.

You may also check and update the values of `sonatypeUri` and `sonatypeSnapshotUri`, which may not be correct if you have a newer Sonatype account (when created after Feb. 2021).

=== Staging Releases

Once you've mixed in `PublishModule`, you can publish your libraries to maven
central via:
Expand Down Expand Up @@ -365,15 +369,20 @@ mill mill.scalalib.PublishModule/publishAll \
--sonatypeSnaphostUri http://example.company.com/snapshot
----

NOTE: That as of Feb. 2021 any new Sonatype accounts have been created on
`s01.oss.sonatype.org`, so you'll want to ensure you set the relevant URIs to
match.
- `https://s01.oss.sonatype.org/service/local` - for the `--sonatypeUri`
- `https://s01.oss.sonatype.org/content/repositories/snapshots` - for `sonatypeSnapshotUri`
[NOTE]
--
Since Feb. 2021 any new Sonatype accounts have been created on
`s01.oss.sonatype.org`, so you'll want to ensure you set the relevant URIs to match.

* `https://s01.oss.sonatype.org/service/local` - for the `--sonatypeUri`
* `https://s01.oss.sonatype.org/content/repositories/snapshots` - for `sonatypeSnapshotUri`
--

=== Non-Staging Releases (classic Maven uploads)

If the site does not support staging release as `oss.sonatype.org` does (for
If the site does not support staging releases as `oss.sonatype.org` and `s01.oss.sonatype.org` do (for
example, a self-hosted OSS nexus site), you can pass in the
`--stagingRelease false` to simply upload release artifacts to corresponding
`--stagingRelease false` option to simply upload release artifacts to corresponding
maven path under `sonatypeUri` instead of staging path.

[source,bash]
Expand Down