Skip to content

Commit

Permalink
Merge pull request #33 from froque/maven-4_incrementals.url
Browse files Browse the repository at this point in the history
Fixes offline instructions due to removal of incrementals.url property
  • Loading branch information
jglick authored Jan 20, 2023
2 parents 4d81dfd + d8c3982 commit 8be1af4
Showing 1 changed file with 19 additions and 11 deletions.
30 changes: 19 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -298,25 +298,33 @@ docker run --rm --name nexus -p 8081:8081 -v nexus-data:/nexus-data sonatype/nex
```

Log in to http://localhost:8081/ and pick an admin password as per instructions, then
add to your `~/.m2/settings.xml`:
edit your `~/.m2/settings.xml` to:

```xml
<servers>
<server>
<id>incrementals</id>
<username>admin</username>
<password>admin123</password>
</server>
</servers>
<settings>
<servers>
<server>
<id>incrementals</id>
<username>admin</username>
<password>admin123</password>
</server>
</servers>
<mirrors>
<mirror>
<id>incrementals-mirror</id>
<url>http://localhost:8081/repository/maven-releases/</url>
<mirrorOf>incrementals</mirrorOf>
</mirror>
</mirrors>
</settings>
```

and then add to command lines consuming or producing incremental versions:
and then add to the command line when producing incremental versions with [maven-deploy-plugin](https://maven.apache.org/plugins/maven-deploy-plugin/deploy-mojo.html):

```
-Dincrementals.url=http://localhost:8081/repository/maven-releases/
-DaltDeploymentRepository=incrementals::http://localhost:8081/repository/maven-releases/
```

or define an equivalent profile in local settings.

## Changelog

Expand Down

0 comments on commit 8be1af4

Please sign in to comment.