Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarify Maven configuration parameter "includes" and "excludes" #228

Closed
kwin opened this issue Apr 5, 2023 · 2 comments · Fixed by #229
Closed

Clarify Maven configuration parameter "includes" and "excludes" #228

kwin opened this issue Apr 5, 2023 · 2 comments · Fixed by #229
Assignees
Milestone

Comments

@kwin
Copy link
Contributor

kwin commented Apr 5, 2023

Currently the javadoc of includes and excludes (

/**
* List of patterns matching all class files to be parsed from the classesDirectory.
* Can be changed to e.g. exclude several files (using excludes).
* The default is a single include with pattern '**/*.class'
* @see #excludes
* @since 1.0
*/
@Parameter(required = false)
private String[] includes;
/**
* List of patterns matching class files to be excluded from checking.
* @see #includes
* @since 1.0
*/
@Parameter(required = false)
private String[] excludes;
) only refer to generic pattern. It should be clarified that this is not a regular expression pattern but an Ant-style one (https://ant.apache.org/manual/dirtasks.html#patterns). Additionally it should be clarified that this is matched against the relative path of the class file (relative to build.outputDirectory, https://maven.apache.org/ref/3.9.1/maven-model/maven.html#build).

Those javadocs are used to generate the Maven site documentation at https://jenkins.thetaphi.de/job/Forbidden-APIs/javadoc/check-mojo.html#excludes.

@uschindler
Copy link
Member

I will add a note to clarify this. For directory patterns the use of ant include/exclude patterns is common in Gradle/Ant world so I assumed that in Maven it is also common.

@kwin
Copy link
Contributor Author

kwin commented Apr 5, 2023

I am preparing a PR clarifying this and also upgrading to the newest m-plugin-p allowing you to render links to javadoc in Maven sites for plugins.

kwin added a commit to kwin/forbidden-apis that referenced this issue Apr 5, 2023
@uschindler uschindler added this to the 3.6 milestone May 20, 2023
@uschindler uschindler self-assigned this May 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

2 participants