> -----Original Message----- > From: Marvin Humphrey [mailto:[email protected]] > Sent: Tuesday, 15 March 2011 4:41 AM > To: [email protected] > Subject: Re: CLI exclude syntax > > Stefan, > > Thank you for your articulate reply. > > On Mon, Mar 14, 2011 at 05:26:17PM +0100, Stefan Bodewig wrote: > > RAT creates a commons-io WildcardFileFilter from each exclude provided > > which behaves like Unix glob matchers (* and ? work like expected), > > except that they are applied to the children of a directory > > immediately. This means you can only match on the filename but not on > > its path. > > Would it be acceptable to provide a patch for RAT which changes this > behavior to work on paths? > > A couple different approaches are possible. > > * Modify the interface for -e/--exclude > * Introduce a new command line flag. > > > > For obvious reasons, it's not acceptable to exclude on filename or > > > file extension alone. > > > > But this is the only exclusion mechanism that is currently implemented > > inside the CLI, sorry. > > Perhaps I just don't undertand the rationale, but to me, that seems like an > odd design. Apparently the Ant and Maven interfaces allow path-based > exclusions, so is the behavior of the CLI a bug? > > > My guess is that most users of RAT don't use the CLI but either the > > Maven plugin or the Ant task which both provide superior methods to > > filter the files to be checked. > > That sounds likely. However, Lucy is a C project with dynamic language > bindings, and does not currently incorporate Ant or Maven; few of us in the > Lucy community have expertise with either. Between that and the > contention that build system discussions tend to provoke, I don't think it's in > the project's interest to introduce Ant into our ecosystem just for this. > > Instead, I'd be inclined to either attempt a nasty hack that wraps RAT and > tries to deal with false matches somehow, or accept that RAT is imperfect > under the best of circumstances and is simply more imperfect when used > from the command line.
A solution could be: Allow ASF Buildbot to check your RAT files for you and publish them for review: See: http://ci.apache.org/projects/rat-master-summary.html Clicking on each project name will take you to a html version of the RAT report. RAT reports are usually triggered on a per commit basis so the reports are pretty upto date right away. see also: http://ci.apache.org/projects/ and http://ci.apache.org/buildbot.html for more info on what the ASF Buildbot can do for you. No need to have Buildbot do anything else for you, every project is quite entitled to just have Buildbot do RAT reports for you. Make sure you look at the working project examples of RAT exclude files. [1] All you need do is maintain your own list of files to exclude from RAT reports, keep it is svn and Buildbot will do the rest. Let me know if you are sold on this idea and I'll set you up. ;) Gav... [1] http://svn.apache.org/repos/asf/subversion/trunk/tools/dist/rat-excludes http://svn.apache.org/repos/asf/incubator/libcloud/trunk/.ratignore http://svn.apache.org/repos/asf/forrest/trunk/etc/rat-avoid.txt > > Marvin Humphrey
