uschindler commented on a change in pull request #533:
URL: https://github.com/apache/lucene/pull/533#discussion_r771319925



##########
File path: gradle/validation/ecj-lint.gradle
##########
@@ -60,6 +61,16 @@ allprojects {
         def tmpDst = getTemporaryDir()
         workingDir tmpDst
 
+        // Place input files in an external file to dodge command line argument
+        // limits. We could pass a directory but ecj seems to be buggy: when it
+        // encounters a module-info.java file it no longer compiles other 
source files.
+        def inputsFile = file("${tmpDst}/ecj-inputs.txt")
+        inputsFile.setText(
+            srcDirs.collectMany { dir ->
+              project.fileTree(dir: dir, include: "**/*.java" ).files
+            }
+            .collect {file -> file.absolutePath.toString()}.join("\n"), 
"UTF-8")

Review comment:
       This fix complies with ECJ's parser: 
db9dff225ce389eaec8341346a0e32e3cc8aa06d
   
   Input file now looks like:
   ```
   C:\Users\Uwe" 
"Schindler\Projects\lucene\lucene\lucene\core\src\java\module-info.java
   C:\Users\Uwe" 
"Schindler\Projects\lucene\lucene\lucene\core\src\java\org\apache\lucene\analysis\AbstractAnalysisFactory.java
   C:\Users\Uwe" 
"Schindler\Projects\lucene\lucene\lucene\core\src\java\org\apache\lucene\analysis\AnalysisSPILoader.java
   C:\Users\Uwe" 
"Schindler\Projects\lucene\lucene\lucene\core\src\java\org\apache\lucene\analysis\Analyzer.java
   ```




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to