[build] Default behavior is to skip the Xtend compiler; activate it with -PcompileXtend=true

This commit is contained in:
Miro Spönemann 2017-01-06 13:56:39 +01:00
parent c8fc186e31
commit c5d26b41b5
4 changed files with 6 additions and 6 deletions

2
Jenkinsfile vendored
View file

@ -10,7 +10,7 @@ node {
stage 'Gradle Build'
try {
sh "./gradlew -PuseJenkinsSnapshots=true clean build createLocalMavenRepo --refresh-dependencies --continue"
sh "./gradlew clean build createLocalMavenRepo -PuseJenkinsSnapshots=true -PcompileXtend=true --refresh-dependencies --continue"
} finally {
step([$class: 'JUnitResultArchiver', testResults: '**/build/test-results/test/*.xml'])
}

View file

@ -25,7 +25,7 @@ subprojects {
version = rootProject.version
apply plugin: 'java'
if (findProperty('skipXtendCompiler') != 'true') {
if (findProperty('compileXtend') == 'true') {
apply plugin: 'org.xtext.xtend'
}
apply plugin: 'eclipse'

View file

@ -16,10 +16,10 @@ sourceSets {
srcDirs = sourceDirs
exclude '**/*.java', '**/*.xtend'
}
if (findProperty('skipXtendCompiler') == 'true') {
java.srcDir 'xtend-gen'
} else {
if (findProperty('compileXtend') == 'true') {
xtendOutputDir = 'xtend-gen'
} else {
java.srcDir 'xtend-gen'
}
}
configure(isTestProject? main : test) {

View file

@ -2,7 +2,7 @@
* Configuration of Xtend compiler.
*/
if (findProperty('skipXtendCompiler') != 'true') {
if (findProperty('compileXtend') == 'true') {
[generateXtext, generateTestXtext].each { gen ->
gen.xtextClasspath = rootProject.configurations.getByName('xtendCompiler')
}