Author: jfclere Date: Sun Dec 18 10:10:33 2011 New Revision: 1220360 URL: http://svn.apache.org/viewvc?rev=1220360&view=rev Log: Fix the deploy-release task to use nexus.
Added: tomcat/tc7.0.x/trunk/res/maven/README.txt Modified: tomcat/tc7.0.x/trunk/res/maven/mvn-pub.xml tomcat/tc7.0.x/trunk/res/maven/mvn.properties.default Added: tomcat/tc7.0.x/trunk/res/maven/README.txt URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/res/maven/README.txt?rev=1220360&view=auto ============================================================================== --- tomcat/tc7.0.x/trunk/res/maven/README.txt (added) +++ tomcat/tc7.0.x/trunk/res/maven/README.txt Sun Dec 18 10:10:33 2011 @@ -0,0 +1,25 @@ +================================================================================ + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You under the Apache License, Version 2.0 + (the "License"); you may not use this file except in compliance with + the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +================================================================================ + +$Id$ + +To release do the following: +1 - copy mvn.properties.default to mvn.propertie and adjust it. +2 - ant -f mvn-pub.xml deploy-release + that step creates a staging in https://repository.apache.org/index.html#stagingRepositories +3 - test it and do the vote process +4 - in https://repository.apache.org/index.html#stagingRepositories close it and then promote it. Modified: tomcat/tc7.0.x/trunk/res/maven/mvn-pub.xml URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/res/maven/mvn-pub.xml?rev=1220360&r1=1220359&r2=1220360&view=diff ============================================================================== --- tomcat/tc7.0.x/trunk/res/maven/mvn-pub.xml (original) +++ tomcat/tc7.0.x/trunk/res/maven/mvn-pub.xml Sun Dec 18 10:10:33 2011 @@ -32,6 +32,8 @@ tomcat.pom.path - the path to the POM files For passwordless upload you'll also need to set + maven.username - YOUR APACHE LDAP USERNAME (ASF ID normally). + maven.password - YOUR APACHE LDAP PASSWORD maven.scp.username - Your ASF ID maven.scp.privateKey - Path to your exported ssh key @@ -60,6 +62,35 @@ <artifact:install-provider artifactId="wagon-ssh" version="1.0-beta-2"/> </target> + <target name="maven-deploy-nexus" depends="init-maven" if="nexus.set"> + <!--deploy it in nexus --> + <artifact:deploy file="${file}"> + <pom file="${pom}.tmp"/> + <remoteRepository url="${maven.repo.url}" layout="default"> + <authentication username="${maven.username}" password="${maven.password}"/> + </remoteRepository> + <attach file="${file}.asc" type="jar.asc"/> + <attach file="${src}" classifier="sources" type="jar"/> + <attach file="${src}.asc" classifier="sources" type="jar.asc"/> + <attach file="${pom}.asc" type="pom.asc"/> + </artifact:deploy> + </target> + + <target name="maven-deploy-other" depends="init-maven" unless="nexus.set"> + <!--deploy it in nexus --> + <artifact:deploy file="${file}"> + <pom file="${pom}.tmp"/> + <remoteRepository url="${maven.repo.url}" layout="default"> + <authentication username="${maven.scp.username}" privateKey="${maven.scp.privateKey}" passphrase="${maven.scp.passphrase}"/> + <authentication username="${maven.username}" password="${maven.password}"/> + </remoteRepository> + <attach file="${file}.asc" type="jar.asc"/> + <attach file="${src}" classifier="sources" type="jar"/> + <attach file="${src}.asc" classifier="sources" type="jar.asc"/> + <attach file="${pom}.asc" type="pom.asc"/> + </artifact:deploy> + </target> + <target name="maven-deploy" depends="init-maven"> <!--cleanup--> <delete file="${pom}.tmp"/> @@ -100,16 +131,16 @@ </exec> <!--deploy it--> - <artifact:deploy file="${file}"> - <pom file="${pom}.tmp"/> - <remoteRepository url="${maven.repo.url}" layout="default"> - <authentication username="${maven.scp.username}" privateKey="${maven.scp.privateKey}" passphrase="${maven.scp.passphrase}"/> - </remoteRepository> - <attach file="${file}.asc" type="jar.asc"/> - <attach file="${src}" classifier="sources" type="jar"/> - <attach file="${src}.asc" classifier="sources" type="jar.asc"/> - <attach file="${pom}.asc" type="pom.asc"/> - </artifact:deploy> + <antcall target="maven-deploy-nexus"> + <param name="file" value="${file}"/> + <param name="pom" value="${pom}"/> + <param name="src" value="${src}"/> + </antcall> + <antcall target="maven-deploy-other"> + <param name="file" value="${file}"/> + <param name="pom" value="${pom}"/> + <param name="src" value="${src}"/> + </antcall> <delete file="${pom}.tmp"/> <delete file="${pom}.asc"/> @@ -319,6 +350,7 @@ </target> <target name="deploy-release"> + <property name="nexus.set" value="true"/> <antcall target="generic-deploy"> <param name="maven.repo.repositoryId" value="${maven.asf.release.repo.repositoryId}"/> <param name="maven.repo.url" value="${maven.asf.release.repo.url}"/> Modified: tomcat/tc7.0.x/trunk/res/maven/mvn.properties.default URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/res/maven/mvn.properties.default?rev=1220360&r1=1220359&r2=1220360&view=diff ============================================================================== --- tomcat/tc7.0.x/trunk/res/maven/mvn.properties.default (original) +++ tomcat/tc7.0.x/trunk/res/maven/mvn.properties.default Sun Dec 18 10:10:33 2011 @@ -20,6 +20,8 @@ # #Maven properties +maven.username=<!-- YOUR APACHE LDAP USERNAME --> +maven.password=<!-- YOUR APACHE LDAP PASSWORD --> maven.scp.username=fhanik maven.scp.privateKey=${user.home}/.ssh/id_rsa.export maven.scp.passphrase= @@ -35,8 +37,8 @@ maven.release.repo.url=scp://people.apac maven.release.repo.repositoryId=tomcat-staging maven.release.deploy.version=7.0.24 -#Maven release properties for the main ASF repo -maven.asf.release.repo.url=scp://people.apache.org/www/people.apache.org/repo/m2-ibiblio-rsync-repository +#Maven release properties for the main ASF repo (staging in nexus) +maven.asf.release.repo.url=https://repository.apache.org/service/local/staging/deploy/maven2 maven.asf.release.repo.repositoryId=apache.releases maven.asf.release.deploy.version=7.0.24 --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org