Created
May 19, 2012 05:24
-
-
Save ALRubinger/2729351 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Is there anything you would do to make this read simpler? Please post in the Gist comments your thoughts! | |
Proposed Code: | |
final File[] shorthand = Maven.resolver().addDependency("G:A:V").addExclusion().groupId("G1").artifactId("A1") | |
.endExclusion().addExclusion("G2:A2").resolve().withTransitivity().as(File.class); | |
...is equivalent to: | |
<dependency> | |
<groupId>G</groupId> | |
<artifactId>A</artifactId> | |
<version>V</version> | |
<exclusions> | |
<exclusion> | |
<groupId>G1</groupId> | |
<artifactId>A1</artifactId> | |
</exclusion> | |
<exclusion> | |
<groupId>G2</groupId> | |
<artifactId>A2</artifactId> | |
</exclusion> | |
</exclusions> | |
</dependency> |
jclouds
commented
May 19, 2012
via email
+1 for stringified coordinate syntax.
…On May 19, 2012 5:21 AM, "Andrew Lee Rubinger" < ***@***.***> wrote:
Agreed Guillaume; the code you've got there _is_ currently supported as
well.
It actually makes me wonder what exactly the use case is for having
the builder (for groupId(), artifactId(), etc.)...
---
Reply to this email directly or view it on GitHub:
https://gist.github.com/2729351
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment