You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tapestry.apache.org by hl...@apache.org on 2012/07/14 01:43:07 UTC

[7/7] git commit: Compile test coffeescript files

Compile test coffeescript files


Project: http://git-wip-us.apache.org/repos/asf/tapestry-5/repo
Commit: http://git-wip-us.apache.org/repos/asf/tapestry-5/commit/98a68ad7
Tree: http://git-wip-us.apache.org/repos/asf/tapestry-5/tree/98a68ad7
Diff: http://git-wip-us.apache.org/repos/asf/tapestry-5/diff/98a68ad7

Branch: refs/heads/5.4-js-rewrite
Commit: 98a68ad7e56b33971ac5a7e271999fb5e32b7515
Parents: 83d6848
Author: Howard M. Lewis Ship <hl...@apache.org>
Authored: Fri Jul 13 15:55:23 2012 -0700
Committer: Howard M. Lewis Ship <hl...@apache.org>
Committed: Fri Jul 13 15:55:23 2012 -0700

----------------------------------------------------------------------
 tapestry-core/build.gradle |   30 +++++++++++++++++++++++-------
 1 files changed, 23 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tapestry-5/blob/98a68ad7/tapestry-core/build.gradle
----------------------------------------------------------------------
diff --git a/tapestry-core/build.gradle b/tapestry-core/build.gradle
index c8a9e3d..9cdf2f7 100644
--- a/tapestry-core/build.gradle
+++ b/tapestry-core/build.gradle
@@ -4,7 +4,8 @@ description = "Central module for Tapestry, containing all core services and com
 
 project.ext { 
   antlrSource = "src/main/antlr"
-  antlrOutput = "$buildDir/generated-sources/antlr"
+  generatedDir = "$buildDir/generated-sources"
+  antlrOutput = "$generatedDir/antlr"
 }
 
 apply from: "coffeescript.gradle"
@@ -54,22 +55,37 @@ task generateGrammarSource(type: JavaExec) {
   }
 }
 
-task compileCoffeeScript(type: CompileCoffeeScript)
+task compileCoffeeScript(type: CompileCoffeeScript) { 
+  outputDir "${generatedDir}/compiled-coffeescript"
+}
+
+task compileTestCoffeeScript(type: CompileCoffeeScript) {
+    srcDir "src/test/coffeescript"
+    outputDir "${generatedDir}/compiled-test-coffeescript"
+}
 
 processResources { 
   from compileCoffeeScript
 }
 
-ideaModule.dependsOn generateGrammarSource
+processTestResources {
+  dependsOn processResources
+  from compileTestCoffeeScript
+}
+
+idea.module { 
+  // dependsOn generateGrammarSource
 
-def generatedDir = file("$buildDir/generated-sources")
+  sourceDirs += compileCoffeeScript.srcDir 
+  sourceDirs += compileCoffeeScript.outputDir
 
-def buildMinusGeneratedDir = (buildDir.listFiles() - generatedDir) as Set<File>
+  testSourceDirs += compileTestCoffeeScript.srcDir
+  testSourceDirs += compileTestCoffeeScript.outputDir
 
-idea.module.excludeDirs += buildMinusGeneratedDir
+  excludeDirs.clear()
+}
 
 compileJava.options.fork(memoryMaximumSize: '512m')
-compileJava.dependsOn generateGrammarSource
 
 // Not sure why this is necessary:
 compileTestGroovy.dependsOn compileTestJava