You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by jv...@apache.org on 2004/02/02 14:46:14 UTC

cvs commit: maven-components/maven-mboot/src/bash maven.functions

jvanzyl     2004/02/02 05:46:14

  Modified:    maven-mboot/src/bash maven.functions
  Log:
  o fixing problems where foo() was being used when foo is all that's needed
    as far as bash functions.
  o corrected construction of mboot classpath
  
  Revision  Changes    Path
  1.19      +6 -6      maven-components/maven-mboot/src/bash/maven.functions
  
  Index: maven.functions
  ===================================================================
  RCS file: /home/cvs/maven-components/maven-mboot/src/bash/maven.functions,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- maven.functions	31 Jan 2004 05:28:06 -0000	1.18
  +++ maven.functions	2 Feb 2004 13:46:14 -0000	1.19
  @@ -7,9 +7,9 @@
   
   downloadMBootDependencies()
   {
  -  findAndSetMavenRepoLocal()
  +  findAndSetMavenRepoLocal
     
  -  for i in `cat ${MBOOT_HOME}/bash/deps`
  +  for i in `cat ${MBOOT_HOME}/deps`
     do
       if [ ! -f $repoLocal/$i ]
       then
  @@ -21,13 +21,13 @@
   
   createMBootClasspath()
   {
  -  findAndSetMavenRepoLocal()
  +  findAndSetMavenRepoLocal
     
  -  for i in `cat ${MBOOT_HOME}/bash/deps`
  +  for i in `cat ${MBOOT_HOME}/deps`
     do
  -    MBOOT_CP=${MBOOT_CP}:$i
  +    MBOOT_CP=${MBOOT_CP}:$repoLocal/$i
     done
  -
  +    
     if [ "$cygwin" = "true" ]
     then
       MBOOT_CP=cygpath -pu "$MBOOT_CP"
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: A Patch And a Few Questions

Posted by jn...@sct.com.
Thanks for the quick response, John. Perhaps I should have been a bit 
more clear in my question.

Setting the maven.repo.remote to include my own repository works just 
fine for Maven (in a manner just as you suggested). But the ant plug-in 
does not handle anything but the first repository definition (take a 
look at the plug-in). So an ant build.xml file is generate by the ant 
plug-in, i.e., with the maven.repo.remote set to multiple repositories, 
executing:

   maven ant

produces a build.xml file which references all dependencies from the 
first defined repository; the build.xml does not try to get resources 
from the other remote repositories.

Question is...what's the best way to handle multiple remote 
respositories so the build.xml files produced by "maven ant" will work 
properly?


Thanks,

Jan



John Casey wrote:
> try modifying your project.properties and/or ~/build.properties (to make
> this a global change):
> 
> maven.repo.remote=http://www.ibiblio.org/maven,http://your.local.repo/some/path/to/maven
> 
> That should do what you want...
> 
> -john
> 
> On Mon, 2004-02-02 at 15:41, jnielsen@sct.com wrote:
> 
>>Hi Mavens!
>>
>>I'm a newbie...I've only played with the tool for a few days now, but I 
>>like what I see.
>>
>>Attached is a little patch to the ant plug-in which adds proxy support 
>>to the generated ant build.xml file. I found the patch useful in my 
>>environment, and it appears it'll behave nicely in most other 
>>environments as well.
>>
>>I would like to support the use of multiple remote repositories for the 
>>ant plug-in. One way to do that is to parse the configuration property 
>>for each remote repository, and do ant "<get/>" for each dependency 
>>against each defined repository:
>>
>>   maven.repo.remote
>>
>>Not very nice. And not correct.
>>
>>A little background...I generate a slew of propietary dependencies which 
>>I do not want to publish to Ibiblio. For these dependencies, I use a 
>>local "remote repository", and publish these dependencies to my 
>>repository. For these dependencies, the ant plug-in generated build.xml 
>>file should, therefore, use my repository instead of Ibiblio...but how 
>>do we capture? At first I thought I could include repository information 
>>in the dependency definition, but that does not seem to be supported. Is 
>>that the right approach? And if I modify Maven to do that would the 
>>patch be accepted? :)
>>
>>Alternatively, I could duplicate the Ibiblio repository locally - and 
>>maintain the synchronization - and then redefine the maven.repo.remote 
>>to only use my local repository. Is that the "proper" approach, and if 
>>so what's the best way to keep a local "complete" repository in-synch 
>>with Ibiblio?
>>
>>Any help is much appreciated.
>>
>>
>>Thanks,
>>
>>Jan
>>
>>
>>______________________________________________________________________
>>Index: src/plugin-resources/templates/build.jelly
>>===================================================================
>>RCS file: /home/cvspublic/maven-plugins/ant/src/plugin-resources/templates/build.jelly,v
>>retrieving revision 1.5
>>diff -u -p -r1.5 build.jelly
>>--- src/plugin-resources/templates/build.jelly	16 Oct 2003 07:56:57 -0000	1.5
>>+++ src/plugin-resources/templates/build.jelly	2 Feb 2004 20:13:19 -0000
>>@@ -299,7 +299,13 @@
>>     name="get-deps"
>>     depends="init"
>>     unless="noget">
>>-  
>>+
>>+    <setproxy
>>+	proxyhost="${maven.proxy.host}"
>>+	proxyport="${maven.proxy.port}"
>>+	proxyuser="${maven.proxy.username}"
>>+	proxypassword="${maven.proxy.password}"/>
>>+
>>     <j:forEach var="dep" items="${pom.dependencies}">
>>     <!-- note: this is a valid use of artifactDirectory -->
>>     <get 
>>
>>
>>______________________________________________________________________
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
>>For additional commands, e-mail: dev-help@maven.apache.org
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: A Patch And a Few Questions

Posted by John Casey <jd...@commonjava.org>.
try modifying your project.properties and/or ~/build.properties (to make
this a global change):

maven.repo.remote=http://www.ibiblio.org/maven,http://your.local.repo/some/path/to/maven

That should do what you want...

-john

On Mon, 2004-02-02 at 15:41, jnielsen@sct.com wrote:
> Hi Mavens!
> 
> I'm a newbie...I've only played with the tool for a few days now, but I 
> like what I see.
> 
> Attached is a little patch to the ant plug-in which adds proxy support 
> to the generated ant build.xml file. I found the patch useful in my 
> environment, and it appears it'll behave nicely in most other 
> environments as well.
> 
> I would like to support the use of multiple remote repositories for the 
> ant plug-in. One way to do that is to parse the configuration property 
> for each remote repository, and do ant "<get/>" for each dependency 
> against each defined repository:
> 
>    maven.repo.remote
> 
> Not very nice. And not correct.
> 
> A little background...I generate a slew of propietary dependencies which 
> I do not want to publish to Ibiblio. For these dependencies, I use a 
> local "remote repository", and publish these dependencies to my 
> repository. For these dependencies, the ant plug-in generated build.xml 
> file should, therefore, use my repository instead of Ibiblio...but how 
> do we capture? At first I thought I could include repository information 
> in the dependency definition, but that does not seem to be supported. Is 
> that the right approach? And if I modify Maven to do that would the 
> patch be accepted? :)
> 
> Alternatively, I could duplicate the Ibiblio repository locally - and 
> maintain the synchronization - and then redefine the maven.repo.remote 
> to only use my local repository. Is that the "proper" approach, and if 
> so what's the best way to keep a local "complete" repository in-synch 
> with Ibiblio?
> 
> Any help is much appreciated.
> 
> 
> Thanks,
> 
> Jan
> 
> 
> ______________________________________________________________________
> Index: src/plugin-resources/templates/build.jelly
> ===================================================================
> RCS file: /home/cvspublic/maven-plugins/ant/src/plugin-resources/templates/build.jelly,v
> retrieving revision 1.5
> diff -u -p -r1.5 build.jelly
> --- src/plugin-resources/templates/build.jelly	16 Oct 2003 07:56:57 -0000	1.5
> +++ src/plugin-resources/templates/build.jelly	2 Feb 2004 20:13:19 -0000
> @@ -299,7 +299,13 @@
>      name="get-deps"
>      depends="init"
>      unless="noget">
> -  
> +
> +    <setproxy
> +	proxyhost="${maven.proxy.host}"
> +	proxyport="${maven.proxy.port}"
> +	proxyuser="${maven.proxy.username}"
> +	proxypassword="${maven.proxy.password}"/>
> +
>      <j:forEach var="dep" items="${pom.dependencies}">
>      <!-- note: this is a valid use of artifactDirectory -->
>      <get 
> 
> 
> ______________________________________________________________________
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


A Patch And a Few Questions

Posted by jn...@sct.com.
Hi Mavens!

I'm a newbie...I've only played with the tool for a few days now, but I 
like what I see.

Attached is a little patch to the ant plug-in which adds proxy support 
to the generated ant build.xml file. I found the patch useful in my 
environment, and it appears it'll behave nicely in most other 
environments as well.

I would like to support the use of multiple remote repositories for the 
ant plug-in. One way to do that is to parse the configuration property 
for each remote repository, and do ant "<get/>" for each dependency 
against each defined repository:

   maven.repo.remote

Not very nice. And not correct.

A little background...I generate a slew of propietary dependencies which 
I do not want to publish to Ibiblio. For these dependencies, I use a 
local "remote repository", and publish these dependencies to my 
repository. For these dependencies, the ant plug-in generated build.xml 
file should, therefore, use my repository instead of Ibiblio...but how 
do we capture? At first I thought I could include repository information 
in the dependency definition, but that does not seem to be supported. Is 
that the right approach? And if I modify Maven to do that would the 
patch be accepted? :)

Alternatively, I could duplicate the Ibiblio repository locally - and 
maintain the synchronization - and then redefine the maven.repo.remote 
to only use my local repository. Is that the "proper" approach, and if 
so what's the best way to keep a local "complete" repository in-synch 
with Ibiblio?

Any help is much appreciated.


Thanks,

Jan