Commit d37f1e35 authored by René Schöne's avatar René Schöne
Browse files

Add generated files to generatedSourceDirs.

parent fe54168d
...@@ -37,15 +37,14 @@ dependencies { ...@@ -37,15 +37,14 @@ dependencies {
compile group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.10.0' compile group: 'org.apache.logging.log4j', name: 'log4j-core', version: '2.10.0'
} }
sourceSets { File genSrc = file("src/gen/java")
main { File testGenSrc = file("src/test/java-gen")
java.srcDir "src/gen/java" sourceSets.main.java.srcDir genSrc
java.srcDir "buildSrc/gen/java" sourceSets.main.java.srcDir "buildSrc/gen/java"
} sourceSets.test.java.srcDir testGenSrc
test {
java.srcDir "src/test/java-gen" idea.module.generatedSourceDirs += genSrc
} idea.module.generatedSourceDirs += testGenSrc
}
def versionFile = 'src/main/resources/RelASTVersion.properties' def versionFile = 'src/main/resources/RelASTVersion.properties'
def oldProps = new Properties() def oldProps = new Properties()
...@@ -53,7 +52,7 @@ def oldProps = new Properties() ...@@ -53,7 +52,7 @@ def oldProps = new Properties()
try { try {
file(versionFile).withInputStream { stream -> oldProps.load(stream) } file(versionFile).withInputStream { stream -> oldProps.load(stream) }
version = oldProps['version'] version = oldProps['version']
} catch (e) { } catch (ignored) {
// this happens, if either the properties file is not present, or cannot be read from // this happens, if either the properties file is not present, or cannot be read from
throw new GradleException("File ${versionFile} not found or unreadable. Aborting.") throw new GradleException("File ${versionFile} not found or unreadable. Aborting.")
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment