On Tue, 13 Dec 2022 at 14:09, Gilles Sadowski <[email protected]> wrote: > > Hello. > > I'm at the step that should upload the artefacts to the "nexus" server: > $ JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64 mvn -Duser.name=erans > clean deploy -Prelease > > I get this message: > ---CUT--- > [ERROR] Failed to execute goal > org.apache.maven.plugins:maven-deploy-plugin:2.8.2:deploy > (default-deploy) on project commons-math4-core: Failed to deploy > artifacts: Could not transfer artifact > org.apache.commons:commons-math4-core:jar:4.0-20221213.133952-543 > from/to apache.snapshots.https > (https://repository.apache.org/content/repositories/snapshots): > Transfer failed for > https://repository.apache.org/content/repositories/snapshots/org/apache/commons/commons-math4-core/4.0-SNAPSHOT/commons-math4-core-4.0-20221213.133952-543.jar > 401 Unauthorized > ---CUT--- > > I don't remember that the "apache.snapshots.https" is the right reference > when "-Prelease" is set...
AFAIK the Maven repo type depends on the version; if it contains SNAPSHOT, then it is a snapshot ... You need to ensure that the version in the pom.xml file is set to the desired release version. Note that this must not be done in master/main/trunk; it should only be done in the RC branch > I've also tried (as hinted at in the notes for [RNG]): > $ JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64 mvn -Dusername=erans > -Dcommons.distServer=apache.releases clean deploy -Prelease > > where "apache.releases" is a server identifier defined in my > ~/.m2/settings.xml > file, together with URL > https://repository.apache.org/content/repositories/staging/ > and my ASF username/password. > > Regards, > Gilles > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
