This week's book giveaway is in the OCMJEA forum.
We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line!
See this thread for details.
The moose likes Ant, Maven and Other Build Tools and the fly likes Understanding mvn -e with Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "Understanding mvn -e with "-DeploymentRepository"" Watch "Understanding mvn -e with "-DeploymentRepository"" New topic
Author

Understanding mvn -e with "-DeploymentRepository"

Mike London
Ranch Hand

Joined: Jul 12, 2002
Posts: 1064
Hello,

Our project build, using "mvn -e" includes a -DeploymentRepository argument that points to a repo that's not on the local machine.

I know some of the jar files on that remote repo include up to date jar files we need to build the correct war file.

My question is different, however.

The confusion I have is the name of the argument itself: "DeploymentRepository" as it implies I'm deploying something to that remote repo.

What am I deploying to the remote repo?

Doesn't seem to be a way to remove it and still get a successful build.

Thanks in advance.

- mike
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16022
    
  20

The "-e" option, if memory serves, is just to tell Maven to output a stacktrace if an operation fails and maybe be a bit more verbose about what Maven is doing. So it should be optional.

However, also relying on my memory (which is a chancy thing!), the "-DeploymentRepository" is just plain WRONG!

Maven makes extensive use of the JVM's ability to inject extra definitions into its Environment via the "-D" command-line option. So what you are actually doing is defining a variable named "eploymentRepository".

More likely you should be coding "-DDeploymentRepository", in other words.

Now whether a deployment repository should be a command-line variable is another matter altogether. YMMV, but Maven is intended to give consistent results with minimal prompting. Or, in this case, command-line appendages.

I'd probably code the thing into a profile myself. Less external knowledge required and fewer characters to mis-type (which is always important to me!)


Customer surveys are for companies who didn't pay proper attention to begin with.
Mike London
Ranch Hand

Joined: Jul 12, 2002
Posts: 1064
Tim Holloway wrote:The "-e" option, if memory serves, is just to tell Maven to output a stacktrace if an operation fails and maybe be a bit more verbose about what Maven is doing. So it should be optional.

However, also relying on my memory (which is a chancy thing!), the "-DeploymentRepository" is just plain WRONG!

Maven makes extensive use of the JVM's ability to inject extra definitions into its Environment via the "-D" command-line option. So what you are actually doing is defining a variable named "eploymentRepository".

More likely you should be coding "-DDeploymentRepository", in other words.

Now whether a deployment repository should be a command-line variable is another matter altogether. YMMV, but Maven is intended to give consistent results with minimal prompting. Or, in this case, command-line appendages.

I'd probably code the thing into a profile myself. Less external knowledge required and fewer characters to mis-type (which is always important to me!)


Thanks for your reply, Tim.

Sorry about the typo above. Yes, it should have been -DDeploymentRepository.

Thanks again.

-mike
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Understanding mvn -e with "-DeploymentRepository"