Maven Artifact Resolver Ant Tasks - Transitive Dependency Versions

2020-02-26 Thread Tim N
I've noticed Maven Artifact Resolver Ant Tasks resolves artifacts
differently to both pure maven and Maven Ant Tasks.

For example, in one project I'm looking at, both pure maven and Maven Ant
Tasks resolves a jar to be "activation-1.1.1.jar", but Maven Artifact
Resolver Ant Tasks resolves to "activation-1.1.jar". The dependency tree
gives the following:
mvn dependency:tree -Dverbose -Dincludes=javax.activation:activation
Using Maven 2 dependency tree to get verbose output, which may be
inconsistent with actual Maven 3 resolution
 company:core:jar:1.0.0-SNAPSHOT
 \- company:model:jar:1.0.0-SNAPSHOT:compile
\- com.sun.mail:javax.mail:jar:1.5.6:compile
   \- javax.activation:activation:jar:1.1.1:compile (version managed
from 1.1)

I gather pure maven does the "version managed from 1.1" change that Maven
Artifact Resolver Ant Tasks isn't doing. Is there any way to get the same
behavior? Can you point me to the documentation on this behavior?

The same command above without "verbose":
mvn dependency:tree -Dincludes=javax.activation:activation
company:core:jar:1.0.0-SNAPSHOT
 \- company:model:jar:1.0.0-SNAPSHOT:compile
\- com.sun.mail:javax.mail:jar:1.5.6:compile
   \- javax.activation:activation:jar:1.1.1:compile

The pure maven command I used to download the JARs is:
mvn -U dependency:copy-dependencies -DoutputDirectory=lib-compile
-DincludeScope=compile

In some cases, the JAR is a minor version out and the project won't compile.


Maven Artifact Resolver Ant Tasks - Remote Repositories

2020-02-25 Thread Tim N
Does "Maven Artifact Resolver Ant Tasks" respect remote repositories
defined in the specified POM when resolving?

What about remote repositories the specified POM's parent?


Re: Maven Artifact Resolver Ant Tasks - resolve dependency path

2020-02-20 Thread Tim N
Figured it out...I used  inside 


Maven Ant Tasks to Maven Artifact Resolver Ant Tasks - Calling Maven From Ant

2020-02-20 Thread Tim N
Maven Ant Tasks had some support for calling Maven from Ant:
https://maven.apache.org/ant-tasks/examples/mvn.html.


Is there anything similar in Maven Artifact Resolver Ant Tasks or another
project?


Re: Maven Ant Tasks - Central 501 HTTPS Required

2020-02-18 Thread Tim N
> maven-ant-tasks have been deprecated in favor of Maven Artifact Resolver
Ant Tasks: https://maven.apache.org/resolver-ant-tasks/

Fantastic, I'll give that a go. Is it possible to add a link to that
project from https://maven.apache.org/ant-tasks/ ?


Maven Artifact Resolver Ant Tasks - resolve dependency path

2020-02-18 Thread Tim N
With Maven Ant Task (https://maven.apache.org/ant-tasks/), it was possible
to refer to a dependency on the file-system in ant with, for example,
${org.jacoco:org.jacoco.ant:jar}.

Is it possible to do the same with Maven Artifact Resolver Ant Tasks?


Maven Ant Tasks - Central 501 HTTPS Required

2020-02-13 Thread Tim N
Yes, I'm still using Ant and Ant Maven Tasks, which has now succumbed to
the "501 HTTPS Required" bug.

I tried a quick fix patch (
https://github.com/tntim96/maven-ant-tasks/commit/b5a89db590e54126164d9d50a5062a0cb4be056c),
but not only does the build fail, the resultant JAR still exhibits the
behaviour, I suppose because it's based on maven 2.2.1 which also doesn't
have the HTTPS fix.Upgrading maven versions appears to be non-trivial.

This tool has worked pretty well for me, so I guess I have a few questions
that didn't appear in the FAQ.

Why was it retired? Is there a better approach to calling the Maven from
Ant?

What is the recommended dependency approach in Ant?

Thanks. I would appreciate any help or tips.