mirror of
https://github.com/sigmasternchen/xtext-core
synced 2025-03-15 08:18:55 +00:00
[build] Use build result from xtend-bootstrap job for Xtend compiler, added skipXtendCompiler option
This commit is contained in:
parent
0ebf15db7d
commit
6a13144f08
4 changed files with 24 additions and 12 deletions
|
@ -30,7 +30,9 @@ subprojects {
|
|||
version = rootProject.version
|
||||
|
||||
apply plugin: 'java'
|
||||
apply plugin: 'org.xtext.xtend'
|
||||
if (findProperty('skipXtendCompiler') != 'true') {
|
||||
apply plugin: 'org.xtext.xtend'
|
||||
}
|
||||
apply plugin: 'eclipse'
|
||||
apply plugin: 'maven'
|
||||
|
||||
|
|
|
@ -5,7 +5,10 @@
|
|||
// The repositories to query when constructing the Xtend compiler classpath
|
||||
repositories {
|
||||
jcenter()
|
||||
maven { url 'https://oss.sonatype.org/content/repositories/snapshots' }
|
||||
maven {
|
||||
name 'xtend-bootstrap'
|
||||
url 'http://services.typefox.io/open-source/jenkins/job/xtend-bootstrap/lastStableBuild/artifact/build-result/maven-repository/'
|
||||
}
|
||||
}
|
||||
|
||||
// The Xtend compiler version to use
|
||||
|
@ -28,5 +31,6 @@ configurations {
|
|||
|
||||
dependencies {
|
||||
xtendCompiler "org.eclipse.xtend:org.eclipse.xtend.core:$bootstrapXtendVersion"
|
||||
xtendCompiler "org.eclipse.xtext:org.eclipse.xtext.smap:$bootstrapXtendVersion"
|
||||
xtendCompiler "org.xtext:xtext-gradle-builder:$versions.xtend_plugin"
|
||||
}
|
||||
|
|
|
@ -16,7 +16,11 @@ sourceSets {
|
|||
srcDirs = sourceDirs
|
||||
exclude '**/*.java', '**/*.xtend'
|
||||
}
|
||||
xtendOutputDir = 'xtend-gen'
|
||||
if (findProperty('skipXtendCompiler') == 'true') {
|
||||
java.srcDir 'xtend-gen'
|
||||
} else {
|
||||
xtendOutputDir = 'xtend-gen'
|
||||
}
|
||||
}
|
||||
configure(isTestProject? main : test) {
|
||||
java.srcDirs = []
|
||||
|
|
|
@ -2,17 +2,19 @@
|
|||
* Configuration of Xtend compiler.
|
||||
*/
|
||||
|
||||
[generateXtext, generateTestXtext].each { gen ->
|
||||
gen.xtextClasspath = rootProject.configurations.getByName('xtendCompiler')
|
||||
}
|
||||
|
||||
sourcesJar {
|
||||
from (sourceSets.main.xtendOutputDir) {
|
||||
include '**/*._trace'
|
||||
if (findProperty('skipXtendCompiler') != 'true') {
|
||||
[generateXtext, generateTestXtext].each { gen ->
|
||||
gen.xtextClasspath = rootProject.configurations.getByName('xtendCompiler')
|
||||
}
|
||||
if (name.endsWith('tests')) {
|
||||
from (sourceSets.test.xtendOutputDir) {
|
||||
|
||||
sourcesJar {
|
||||
from (sourceSets.main.xtendOutputDir) {
|
||||
include '**/*._trace'
|
||||
}
|
||||
if (name.endsWith('tests')) {
|
||||
from (sourceSets.test.xtendOutputDir) {
|
||||
include '**/*._trace'
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue