I believe its because deploying a release isn't something you do more than once.

However, you may need to rebuild a release from a tag more than once. You may 
actually need to rebuild many years after a tag was released and your 
environment may have changed since then and thus need to download artifacts 
from a different place. 

> -----Original Message-----
> From: Timothy Mcginnis [mailto:[email protected]] 
> Sent: Monday, May 03, 2010 10:36 AM
> To: [email protected]
> Subject: Why define repositories in settings.xml and pom?
> 
> I am a confused about where repositories need to be defined.
> 
> I have my repositories defined in my settings.xml file under 
> my default profile.
> 
> <profile>
>         <id>default_profile</id>
>         <activation>
>                 <activeByDefault>true</activeByDefault>
>         </activation>
>         <repositories>
>                 <repository>
>                         <id>archiva.internal</id>
>                         <name>Internal Release Repository</name>
>                         <url>
> http://2e02057b.aessuccess.org:8085/archiva/repository/internal/</url>
>                         <snapshots>
>                                 <enabled>false</enabled>
>                         </snapshots>
>                         <releases>
>                                 <enabled>true</enabled>
>                         </releases>
>                 </repository>
>                 <repository>
>                         <id>archiva.snapshots</id>
>                         <name>Internal Snapshot Repository</name>
>                         <url>
> http://2e02057b.aessuccess.org:8085/archiva/repository/snapsho
> ts/</url>
>                         <snapshots>
>                                 <enabled>true</enabled>
>                         </snapshots>
>                         <releases>
>                                 <enabled>false</enabled>
>                         </releases>
>                 </repository>
>         </repositories>
> </profile>
> 
> I thought this would tell Maven where to store and retrieve 
> all my artifacts.  But when I run a deploy it gives me the error
> 
> Deployment failed: repository element was not specified in 
> the pom inside distributionManagement element or in 
> -DaltDeploymentRepository=id::layout::url parameter
> 
> If I define the repositories in the pom using the 
> distributionManagement element it works fine.
> 
> But this seems confusing to me.  Why do I have to define them 
> in both places?
> 
> Tim McGinnis
> 717 720-1962
> Web Development
> AES/PHEAA
> ==============================================================
> ================
> This message contains privileged and confidential information 
> intended for the above addressees only.  If you receive this 
> message in error please delete or destroy this message and/or 
> attachments.  
> 
> The sender of this message will fully cooperate in the civil 
> and criminal prosecution of any individual engaging in the 
> unauthorized use of this message.
> ==============================================================
> ================
> 
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to