I tested your fix.
It works and can retrieves the jars from several repositories.
Some few comments below.
1- The generated build.xml script has the following lines:
<property name="proxy.host" value="${maven.proxy.host}">
</property>
In case you don't have set ${maven.proxy.host}, proxy.host is set to the string "${maven.proxy.host}" so the script is in "useProxy mode".
On execution of the script, ant complains with the following:
BUILD FAILED
<path-to-project>/build.xml:313: java.lang.NumberFormatException: For input string: "${maven.proxy.port}"
In order to succeed you have to explicitly set ${maven.proxy.port} to an empty string. Something like:
$ ant -Dmaven.proxy.host=
which is not something you should have to do.
My first impression is that the two lines that set proxy.host shouldn't be generated when maven.proxy.host is not set in maven.
2- Once the problem above corrected, the ant script execution produce several error messages like:
[get] Error opening connection java.io.FileNotFoundException...
It doesn't affect the final results. It doesn't mean that something really went wrong, just that some jars are not in some repositories which is expected.
Removing these pesky messages would be "la cerise sur le gāteau".
I'm not sure, though, if:
- it's easy.
- it's doable without removing the messages that need to remain (for example if all connection for a give jar failed).
In any case I really appreciate what you have done.
Oscar
Not really easy to do.
Because of
MPANT-20, we define a unique property for each dependency. Using several repositories will break it because we'll need to download several times the same dependency. We'll not be able to do it with a property (which is immutable).What we can do easily is to provide a property which will allow the user to select the repository to use (and not the default ${maven.repo.remote}[0]). Can it help you ?
MPANT-20, we define a unique property for each dependency. Using several repositories will break it because we'll need to download several times the same dependency. We'll not be able to do it with a property (which is immutable). What we can do easily is to provide a property which will allow the user to select the repository to use (and not the default ${maven.repo.remote}[0]). Can it help you ?