Ryan Ernst
added a comment - 13/Jun/13 06:39 Attached is a patch which adds all xml files in each source module to the list of files checked by rat-sources, and fixes the files that were missing the copyright notice.

I improved the patch a littel bit to catch further thins (optionally for some modules):

tools/forbiddenApis/**
This is done by an generally empty property ${rat.additional-includes}, which is defined by those modules. Evereything in this property is a pattern applied to the module's home dir

I found one license problem:

If I add "tools/prettify/**" it complains, because all those Javascript files contain no license header! We should fix this (although they are compressed&unreadable Javascript), but generally Javascript compressors keep license headers!

Uwe Schindler
added a comment - 13/Jun/13 07:24 - edited I improved the patch a littel bit to catch further thins (optionally for some modules):
tools/forbiddenApis/**
This is done by an generally empty property ${rat.additional-includes}, which is defined by those modules. Evereything in this property is a pattern applied to the module's home dir
I found one license problem:
If I add "tools/prettify/**" it complains, because all those Javascript files contain no license header! We should fix this (although they are compressed&unreadable Javascript), but generally Javascript compressors keep license headers!

The patch by Ryan and my modified one was missing to run the checks on the files in the root directory (build.xml, extra-targets.xml). I added this to the root rat-sources target. I had to tweak the rat task a bit, because root has no src dir.

Uwe Schindler
added a comment - 13/Jun/13 07:35 The patch by Ryan and my modified one was missing to run the checks on the files in the root directory (build.xml, extra-targets.xml). I added this to the root rat-sources target. I had to tweak the rat task a bit, because root has no src dir.

Uwe Schindler
added a comment - 13/Jun/13 08:33 - edited With your additional-includes property, can these checks be moved to the modules which need it?
I would keep it like it is for now. By this we automatically do the checks in all modules without taking care which actually need them. This would enforce the checks.
I misunderstood! The extra tools check! Yes we can move those checks! Will do this.

Yeah, but for resources we should take care overall. The problem is, we have sometimes binary files. We have resources folders also in core (the META-INF files). So the resources check should be done globally.

Uwe Schindler
added a comment - 13/Jun/13 08:44 - edited Yeah, but for resources we should take care overall. The problem is, we have sometimes binary files. We have resources folders also in core (the META-INF files). So the resources check should be done globally.

Uwe Schindler
added a comment - 13/Jun/13 08:48 - edited I added:
<fileset dir= "${src.dir}/../resources" excludes= "${rat.excludes}" erroronmissingdir= "no" />
(the way with ${src.dir}/../resources is identical to the copy task in javac)
And now we have some missing Licenses on *.rslp files. It also scans the zip files inside. The pattern might need additional checks.

Attached is a patch that refactors the resources folder handling a little bit (adds a property for it and removes hardcoded ../resources).
For now I only enabled license checking on META-INF/** files. We should discuss what to do with other resources files (maybe only patterns like *.txt).

Uwe Schindler
added a comment - 13/Jun/13 09:35 Attached is a patch that refactors the resources folder handling a little bit (adds a property for it and removes hardcoded ../resources).
For now I only enabled license checking on META-INF/** files. We should discuss what to do with other resources files (maybe only patterns like *.txt).

We should first check the license of those files. I also know that most stopword files are missing licenses, too. Especially it is sometimes unknown, so "relicensing" them might be wrong. I think we should discuss with Robert Muir, too.

Uwe Schindler
added a comment - 13/Jun/13 15:50 We should first check the license of those files. I also know that most stopword files are missing licenses, too. Especially it is sometimes unknown, so "relicensing" them might be wrong. I think we should discuss with Robert Muir , too.

OK, so should we add the whole resources folder (non binary of course) to rat-sources? Currently it fails e.g. for those *.rslp files, because they have no header and look like some programming language... But no header at all. For stop words in most cases we have some "note" (license-Like) - but if its BSD, shouldn't they have a BSD header?

The attached patch for now only check META-INF resources for License headers.

Uwe Schindler
added a comment - 13/Jun/13 16:33 - edited OK, so should we add the whole resources folder (non binary of course) to rat-sources? Currently it fails e.g. for those *.rslp files, because they have no header and look like some programming language... But no header at all. For stop words in most cases we have some "note" (license-Like) - but if its BSD, shouldn't they have a BSD header?
The attached patch for now only check META-INF resources for License headers.

Robert Muir
added a comment - 13/Jun/13 16:45
Currently it fails e.g. for those *.rslp files, because they have no header and look like some programming language... But no header at all.
They are a description of stemming rules, not programming (and ASL2). See RSLPStemmerBase for more documentation or also http://www.inf.ufrgs.br/~viviane/rslp/index.htm for background.

Robert Muir: Doesn't matter to me what they are, the question was just if we can/should enable license checks in resources folders or not. To me it looke like you are against, I just wanted your opinion.

If we decide to not check licenses in resources folder, I will commit the attached patch, which only checks META-INF, build.xml, forbidden-api signatures and cleans up the handling of resources folder in build.xml

Uwe Schindler
added a comment - 13/Jun/13 16:57 Robert Muir : Doesn't matter to me what they are, the question was just if we can/should enable license checks in resources folders or not. To me it looke like you are against, I just wanted your opinion.
If we decide to not check licenses in resources folder, I will commit the attached patch, which only checks META-INF, build.xml, forbidden-api signatures and cleans up the handling of resources folder in build.xml