[
https://issues.apache.org/jira/browse/RAT-240?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17881207#comment-17881207
]
Claude Warren edited comment on RAT-240 at 9/12/24 8:03 AM:
------------------------------------------------------------
This filtering is almost covered in PR #311
This request reworks the exclusion code and moves the functionality that was in
the Maven module into core so everyone can use it.
In that pull there is code in the config/exclusion/fileProcessors directory
that handles reading files like .gitignore or .cvsignore where the file is in
one location and only provides changes for the locations below it.
We have the ability to specify a file on the command line that will exclude all
the patterns below the directory that scanning starts in.
It would be a simple exercize to create a ".ratignore" file parser that would
process all ".ratignore" files in the tree and provided patters at various
levels to ignore (or stop ignoring) them.
If [~pottlinger], [~janc], or [~utzig] are interested in exploring this drop me
a line and I will give you pointers for how to create the processor and we can
discuss how to plug it in. I need to write developer docs anyway so this would
be a good start along that path too.
Also, note that this ticket is part of the Harmonization ticket and will be in
0.17
was (Author: claudenw):
This filtering is almost covered in PR #311
This request reworks the exclusion code and moves the functionality that was in
the Maven module into core so everyone can use it.
In that pull there is code in the config/exclusion/fileProcessors directory
that handles reading files like .gitignore or .cvsignore where the file is in
one location and only provides changes for the locations below it.
We have the ability to specify a file on the command line that will exclude all
the patterns below the directory that scanning starts in.
It would be a simple exercize to create a ".ratignore" file parser that would
process all ".ratignore" files in the tree and provided patters at various
levels to ignore (or stop ignoring) them.
If [~pottlinger], [~janc], or [~utzig] are interested in exploring this drop me
a line and I will give you pointers for how to create the processor and we can
discuss how to plug it in. I need to write developer docs anyway so this would
be a good start along that path too.
> CLI: RAT excludes file does not allow to set a full path
> --------------------------------------------------------
>
> Key: RAT-240
> URL: https://issues.apache.org/jira/browse/RAT-240
> Project: Apache Rat
> Issue Type: Sub-task
> Components: Client - cli, scan
> Affects Versions: 0.12
> Reporter: Szymon Janc
> Priority: Major
> Attachments: rat.txt
>
>
> it is not possible to exclude file (or folder) by providing full path
> eg
> foo/foo2/main.c
> bar/bar2/main.c
> it is not possible to match only one of those file from project top directory
> .rat-excludes file.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)