You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by "Ehmann, Brian" <Br...@xmradio.com> on 2007/06/18 18:59:40 UTC
Set alternate location for .m2
Hey,
I'm new to maven so forgive me if this is a stupid question or if it has
been previously answered; however I have not found anything on Google.
Can someone tell me how to specify a custom location of the .m2
directory? I need to put this folder outside of the user.home
directory.
Thanks,
Brian Ehmann
Re: Set alternate location for .m2
Posted by Steven Rowe <sa...@syr.edu>.
Hi Brian,
Ehmann, Brian wrote:
> Can someone tell me how to specify a custom location of the .m2
> directory? I need to put this folder outside of the user.home
> directory.
PROMPT$ mvn --help
usage: mvn [options] [<goal(s)>] [<phase(s)>]
Options:
[snip]
-s,--settings Alternate path for the user settings file
[snip]
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
RE: Set alternate location for .m2
Posted by "Ehmann, Brian" <Br...@xmradio.com>.
That will let me set the repository location, but I'd like to set the
.m2 directory location since I will need to create a custom settings.xml
file that will go inside of the .m2 directory.
-----Original Message-----
From: Mick Knutson [mailto:mickknutson@gmail.com]
Sent: Monday, June 18, 2007 1:05 PM
To: Maven Users List
Subject: Re: Set alternate location for .m2
in you settings.xml:
<settings>
<localRepository>c:\opt\.m2\repository</localRepository>
</settings>
On 6/18/07, Ehmann, Brian <Br...@xmradio.com> wrote:
>
> Hey,
>
>
>
> I'm new to maven so forgive me if this is a stupid question or if it
has
> been previously answered; however I have not found anything on Google.
>
>
>
> Can someone tell me how to specify a custom location of the .m2
> directory? I need to put this folder outside of the user.home
> directory.
>
>
>
> Thanks,
>
>
>
> Brian Ehmann
>
>
--
---
Thanks,
Mick Knutson
http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Set alternate location for .m2
Posted by Mick Knutson <mi...@gmail.com>.
in you settings.xml:
<settings>
<localRepository>c:\opt\.m2\repository</localRepository>
</settings>
On 6/18/07, Ehmann, Brian <Br...@xmradio.com> wrote:
>
> Hey,
>
>
>
> I'm new to maven so forgive me if this is a stupid question or if it has
> been previously answered; however I have not found anything on Google.
>
>
>
> Can someone tell me how to specify a custom location of the .m2
> directory? I need to put this folder outside of the user.home
> directory.
>
>
>
> Thanks,
>
>
>
> Brian Ehmann
>
>
--
---
Thanks,
Mick Knutson
http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---
Re: Set alternate location for .m2
Posted by Olivier Jacob <ol...@gmail.com>.
> Hey,
>
> I'm new to maven so forgive me if this is a stupid question or if it has
> been previously answered; however I have not found anything on Google.
>
> Can someone tell me how to specify a custom location of the .m2
> directory? I need to put this folder outside of the user.home
> directory.
Hi,
you can add -Duser.home=<path> in your MAVEN_OPTS env variable, where <path>
is the path to the folder
containing you .m2 directory.
--
Olivier Jacob
Consultant - OCTO Technology
50, avenue des Champs Elysées
75008 Paris