205 lines
5.7 KiB
Groovy
205 lines
5.7 KiB
Groovy
buildscript {
|
|
repositories {
|
|
mavenCentral()
|
|
mavenLocal()
|
|
if (project.hasProperty('fatJar')) jcenter()
|
|
}
|
|
dependencies {
|
|
classpath "pl.allegro.tech.build:axion-release-plugin:1.3.4"
|
|
classpath "com.bmuschko:gradle-nexus-plugin:2.3"
|
|
classpath "io.codearte.gradle.nexus:gradle-nexus-staging-plugin:0.5.3"
|
|
if (project.hasProperty('fatJar')) classpath 'com.github.jengelman.gradle.plugins:shadow:1.2.3'
|
|
}
|
|
}
|
|
|
|
apply plugin: "pl.allegro.tech.build.axion-release"
|
|
|
|
scmVersion {
|
|
tag { prefix = "accurest" }
|
|
createReleaseCommit = true
|
|
releaseCommitMessage { version, position -> "Release version: ${version}\n\n[ci skip]" }
|
|
hooks {
|
|
pre "fileUpdate", [file : "README.md",
|
|
pattern : { v, p -> /'io\.codearte\.accurest:accurest-gradle-plugin:.*'/ },
|
|
replacement: { v, p -> "'io.codearte.accurest:accurest-gradle-plugin:$v'" }]
|
|
}
|
|
}
|
|
|
|
allprojects {
|
|
project.version = scmVersion.version
|
|
}
|
|
|
|
apply plugin: 'io.codearte.nexus-staging'
|
|
|
|
nexusStaging {
|
|
packageGroup = "io.codearte"
|
|
stagingProfileId = '93c08fdebde1ff'
|
|
}
|
|
|
|
subprojects {
|
|
apply plugin: 'groovy'
|
|
apply from: "$rootDir/gradle/release.gradle"
|
|
|
|
group = 'io.codearte.accurest'
|
|
|
|
sourceCompatibility = 1.7
|
|
targetCompatibility = 1.7
|
|
|
|
repositories {
|
|
mavenLocal()
|
|
mavenCentral()
|
|
jcenter()
|
|
maven {
|
|
url "http://repo.spring.io/milestone"
|
|
}
|
|
}
|
|
|
|
//Dependencies in all subprojects - http://solidsoft.wordpress.com/2014/11/13/gradle-tricks-display-dependencies-for-all-subprojects-in-multi-project-build/
|
|
task allDeps(type: DependencyReportTask) {}
|
|
task allInsight(type: DependencyInsightReportTask) {}
|
|
|
|
dependencies {
|
|
compile localGroovy()
|
|
testCompile('org.spockframework:spock-core:1.0-groovy-2.4') {
|
|
exclude(group: 'org.codehaus.groovy')
|
|
}
|
|
testCompile 'info.solidsoft.spock:spock-global-unroll:0.5.0'
|
|
}
|
|
|
|
test {
|
|
testLogging {
|
|
exceptionFormat = 'full'
|
|
}
|
|
}
|
|
|
|
// fixing the groovydoc issue http://stackoverflow.com/questions/20618857/gradle-task-groovydoc-failing-with-noclassdeffounderror
|
|
configurations {
|
|
jansi.extendsFrom(runtime)
|
|
}
|
|
groovydoc {
|
|
def title = "IPDS ${version}"
|
|
groovyClasspath = project.configurations.jansi
|
|
}
|
|
dependencies {
|
|
jansi 'org.fusesource.jansi:jansi:1.11'
|
|
}
|
|
}
|
|
|
|
project(':accurest-core') {
|
|
|
|
dependencies {
|
|
compile 'org.slf4j:slf4j-api:[1.6.0,)'
|
|
compile 'org.codehaus.plexus:plexus-utils:[3.0.0,)'
|
|
compile 'commons-io:commons-io:[2.0,)'
|
|
compile 'org.apache.commons:commons-lang3:[3.3,)'
|
|
compile 'com.google.code.gson:gson:2.3.1'
|
|
compile 'com.fasterxml.jackson.core:jackson-databind:2.4.5'
|
|
compile 'asm:asm:3.3.1'
|
|
compile "com.github.tomakehurst:wiremock:$wiremockVersion"
|
|
compile "com.toomuchcoding.jsonassert:jsonassert:$jsonassertVersion"
|
|
compile 'org.assertj:assertj-core:2.3.0'
|
|
compile localGroovy()
|
|
testCompile 'cglib:cglib-nodep:2.2'
|
|
testCompile 'org.objenesis:objenesis:2.1'
|
|
testCompile project(':accurest-testing-utils')
|
|
}
|
|
|
|
}
|
|
|
|
project(':accurest-testing-utils') {
|
|
|
|
dependencies {
|
|
compile 'org.skyscreamer:jsonassert:1.2.3'
|
|
}
|
|
|
|
}
|
|
|
|
project(':accurest-converters') {
|
|
dependencies {
|
|
compile project(':accurest-core')
|
|
compile 'org.apache.commons:commons-lang3:[3.0,)'
|
|
compile 'commons-io:commons-io:[2.0,)'
|
|
compile 'dk.brics.automaton:automaton:1.11-8' // needed for Xeger
|
|
testCompile "com.github.tomakehurst:wiremock:$wiremockVersion"
|
|
testCompile 'org.hamcrest:hamcrest-all:1.3'
|
|
}
|
|
}
|
|
|
|
project(':accurest-gradle-plugin') {
|
|
|
|
ext.messagingLibsDir ="$buildDir/messaging-libs"
|
|
ext.accurestGradlePluginLibsDir ="$buildDir/accurest-gradle-plugin-libs"
|
|
|
|
ext.testSystemProperties = [
|
|
'accurest-gradle-plugin-libs-dir': accurestGradlePluginLibsDir,
|
|
'messaging-libs-dir': messagingLibsDir
|
|
]
|
|
|
|
dependencies {
|
|
compile project(':accurest-core')
|
|
compile project(':accurest-converters')
|
|
compile gradleApi()
|
|
|
|
testCompile gradleTestKit()
|
|
testCompile project(':accurest-testing-utils')
|
|
}
|
|
|
|
configurations {
|
|
messagingLibs
|
|
accurestGradlePluginLibs
|
|
}
|
|
|
|
dependencies {
|
|
messagingLibs project(':accurest-messaging-root:accurest-messaging-integration')
|
|
messagingLibs project(':accurest-messaging-root:accurest-messaging-core')
|
|
messagingLibs project(':accurest-testing-utils')
|
|
messagingLibs 'org.codehaus.groovy:groovy-all:2.4.5'
|
|
|
|
accurestGradlePluginLibs project(':accurest-gradle-plugin')
|
|
}
|
|
|
|
test {
|
|
exclude '**/*FunctionalSpec.*'
|
|
systemProperties = testSystemProperties
|
|
}
|
|
task funcTest(type: Test) {
|
|
include '**/*FunctionalSpec.*'
|
|
systemProperties = testSystemProperties
|
|
reports.html {
|
|
destination = file("${reporting.baseDir}/funcTests")
|
|
}
|
|
}
|
|
|
|
task archiveMessagingLibsDependencies(type: Sync) {
|
|
from configurations.messagingLibs.resolvedConfiguration.resolvedArtifacts.collect { it.file }
|
|
into messagingLibsDir
|
|
}
|
|
|
|
task archiveAccurestGradlePluginLibsDependencies(type: Sync) {
|
|
from configurations.accurestGradlePluginLibs.resolvedConfiguration.resolvedArtifacts.collect { it.file }
|
|
into accurestGradlePluginLibsDir
|
|
}
|
|
|
|
// archive task needs to have jars ready
|
|
archiveMessagingLibsDependencies.dependsOn project(':accurest-messaging-root:accurest-messaging-integration').tasks.jar
|
|
archiveAccurestGradlePluginLibsDependencies.dependsOn project(':accurest-gradle-plugin').tasks.jar
|
|
|
|
test.dependsOn archiveMessagingLibsDependencies, archiveAccurestGradlePluginLibsDependencies
|
|
funcTest.dependsOn archiveMessagingLibsDependencies, archiveAccurestGradlePluginLibsDependencies
|
|
|
|
uploadArchives.dependsOn { funcTest }
|
|
}
|
|
|
|
// REMOVE AFTER https://issues.gradle.org/browse/GRADLE-3433 IS FIXED
|
|
buildscript {
|
|
repositories {
|
|
maven {
|
|
url "https://plugins.gradle.org/m2/"
|
|
}
|
|
}
|
|
dependencies {
|
|
classpath "gradle.plugin.com.palantir.ideatestfix:gradle-idea-test-fix:0.1.0"
|
|
}
|
|
}
|
|
|
|
apply plugin: "com.palantir.idea-test-fix" |