apache / apache/maven-dependency-plugin

[MDEP-196] Coherence between dependency:tree and dependency:list include/exclude options

Open
#1,101 2 comments 0 reactions 0 assignees View on GitHub
bug priority:minor
Dominant language
Java
Stars
175
Forks
196
Avg merge
19h 30m
Merged PRs (30d)
5

Description

**[Baptiste MATHUS](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=mathus.b@mipih.fr)** opened **[MDEP-196](https://issues.apache.org/jira/browse/MDEP-196?redirect=false)** and commented

(The "list" component seems to be missing. That's why I only selected the "tree" one).

I think dependency:tree and dependency:list should at least try to share the same filtering options. For example, I just ran this on my project:

> mvn dependency:tree -Dincludes=org.springframework
> Then I wanted to see the resulting list after the transitive dependency resolution, so I just replaced tree by list:
> mvn dependency:list -Dincludes=org.springframework

But indeed this won't work, since for dependency:list you have to put -DincludeGroupIds instead of -Dincludes.

What it should do in my opinion:
1. both should support a very simple -Dincludes/-Dexcludes option that would just do a simple kind of grep inside the groupId/artifact (even version ?)
2. both should then also support -DincludeGroupIds/includeArtifactIds as specific options.

This would improve the global usability and coherence of the plugin. Also note that other mojos of the dependency-plugin could be improved by this unification (resolve*, sources, unpack...).

Thanks a lot.
Cheers.

---

**Affects:** 2.0

**Issue Links:**
- [MDEP-502](https://issues.apache.org/jira/browse/MDEP-502) Add parameter "includes" to dependency:list
(_**"is duplicated by"**_)

2 votes, 3 watchers

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by comparing the dependency:tree and dependency:list mojos and their documented filtering parameters, using the example commands in the issue. Check the linked MDEP-502 duplicate and the other dependency-plugin mojos mentioned. Done means the relevant mojos share -Dincludes/-Dexcludes behavior while retaining the specific group and artifact ID options.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
build-system
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.