The moose likes Ant, Maven and Other Build Tools and the fly likes Maven Question on distribution management Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "Maven Question on distribution management" Watch "Maven Question on distribution management" New topic

Maven Question on distribution management

Praful Thakare
Ranch Hand

Joined: Feb 10, 2001
Posts: 614

I am testing Archiva with maven and have simplest structure as below.



now when i run mvn deploy -Psnapshots, i want the artifact to be deployed under snapshots on archiva and not under internal so i created profile in settings.xml.

And pom.xml as distribution management as follows

and i exeucte maven as mvn deploy -Psnapshots

still it always tries to deploy to internal.

maven version maven-2.0.7

any help?


All desirable things in life are either illegal, banned, expensive or married to someone else !!!
Greg Charles

Joined: Oct 01, 2001
Posts: 2841

You can run:

mvn -Psnapshots help:active-profiles

just to be sure that the profile you want is actually getting activated. I think though that you may be confusing what you mean by snapshot and what it means to the distributionManagement plugin.
Praful Thakare
Ranch Hand

Joined: Feb 10, 2001
Posts: 614
Thanks much for your reply Greg, the output of help:active-profiles is

The following profiles are active:
- snapshots (source: settings.xml)

and now i found that i was using vesion as snapshot instead of SNAPSHOT , all works fine now.

I agree. Here's the link: http://aspose.com/file-tools
subject: Maven Question on distribution management
Similar Threads
Why is Eclipse/Maven project not picking up the values from settings.xml?
Build project from the Local Repository instead of Remote Repository
Maven: Trouble loading a dependency from a local repository
[Maven] Could not find artifact javax.transaction:jta:jar:1.0.1B in central http://repo1.maven.org/
problem with mvn deploy