HHH-12098 - prep 5.3

This commit is contained in:
Steve Ebersole 2017-12-13 09:15:22 -06:00
parent 447f3d57c7
commit d5d3b080f9
2 changed files with 25 additions and 56 deletions

View File

@ -109,15 +109,15 @@ subprojects { subProject ->
// minimize changes, at least for now (gradle uses 'build' by default).. // minimize changes, at least for now (gradle uses 'build' by default)..
buildDir = "target" buildDir = "target"
if ( subProject.name.startsWith( 'release' ) || subProject.name.startsWith( 'documentation' ) ) { if ( subProject.name.startsWith( 'release' ) ) {
return; return
} }
if ( subProject.name.startsWith( 'hibernate-orm-modules' ) ) { if ( subProject.name.startsWith( 'hibernate-orm-modules' ) ) {
return; return
} }
// everything below here in the closure applies to java projects // everything below here in the closure applies to modules with Java code
apply plugin: 'java' apply plugin: 'java'
apply plugin: 'maven-publish' apply plugin: 'maven-publish'
apply plugin: 'maven-publish-auth' apply plugin: 'maven-publish-auth'
@ -455,28 +455,31 @@ subprojects { subProject ->
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Publishing // Publishing
publishing { if ( !subProject.name.equals( 'documentation' ) ) {
publications { // do not configure publishing for the documentation module
mavenJava(MavenPublication) { publishing {
from components.java publications {
mavenJava(MavenPublication) {
from components.java
artifact( sourcesJar ) { artifact( sourcesJar ) {
classifier 'sources' classifier 'sources'
}
} }
// http://issues.gradle.org/browse/GRADLE-2966
// Once ^^ is resolved:
// 1) Move hibernate-testing module into hibernate-core tests
// 2) Define a second publication on hibernate-core for publishing the testing jar
// We could kind of do this now, but it would just be the jar. Every module would still need
// to duplicate the testing dependencies. Well, on second thought, we could centralize the
// testing dependencies here within the subprojects block
} }
// http://issues.gradle.org/browse/GRADLE-2966
// Once ^^ is resolved:
// 1) Move hibernate-testing module into hibernate-core tests
// 2) Define a second publication on hibernate-core for publishing the testing jar
// We could kind of do this now, but it would just be the jar. Every module would still need
// to duplicate the testing dependencies. Well, on second thought, we could centralize the
// testing dependencies here within the subprojects block
} }
}
model { model {
tasks.generatePomFileForMavenJavaPublication { tasks.generatePomFileForMavenJavaPublication {
destination = file( "$subProject.buildDir/generated-pom.xml" ) destination = file( "$subProject.buildDir/generated-pom.xml" )
}
} }
} }
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

View File

@ -1,5 +1,6 @@
import org.apache.tools.ant.filters.ReplaceTokens import org.apache.tools.ant.filters.ReplaceTokens
import org.asciidoctor.gradle.AsciidoctorTask import org.asciidoctor.gradle.AsciidoctorTask
/* /*
* Hibernate, Relational Persistence for Idiomatic Java * Hibernate, Relational Persistence for Idiomatic Java
* *
@ -8,13 +9,6 @@ import org.asciidoctor.gradle.AsciidoctorTask
*/ */
buildscript { buildscript {
repositories { repositories {
mavenCentral()
mavenLocal()
maven {
name 'jboss-nexus'
url "http://repository.jboss.org/nexus/content/groups/public/"
}
jcenter() jcenter()
} }
dependencies { dependencies {
@ -74,19 +68,6 @@ dependencies {
testCompile "org.osgi:org.osgi.core:4.3.1" testCompile "org.osgi:org.osgi.core:4.3.1"
if (db.equalsIgnoreCase("oracle")) {
dependencies {
testRuntime( libraries.oracle ) {
exclude group: 'com.oracle.jdbc', module: 'xmlparserv2'
}
}
}
if (db.equalsIgnoreCase("hana")) {
dependencies {
testRuntime( libraries.hana )
}
}
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Java 9 ftw! // Java 9 ftw!
if ( JavaVersion.current().isJava9Compatible() ) { if ( JavaVersion.current().isJava9Compatible() ) {
@ -113,21 +94,6 @@ dependencies {
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
} }
processTestResources.doLast( {
copy {
from( sourceSets.test.java.srcDirs ) {
include '**/*.properties'
include '**/*.xml'
}
into sourceSets.test.output.classesDir
}
copy {
ext.targetDir = file( "${buildDir}/resources/test" )
from file('src/test/resources')
into targetDir
filter( ReplaceTokens, tokens: dbBundle[db] );
}
} )
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// grouping tasks - declaration, see below for task dependency definitions // grouping tasks - declaration, see below for task dependency definitions