forked from hibernate/hibernate-matrix-testing
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
126 lines (109 loc) · 3.8 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
buildscript {
repositories {
mavenCentral()
mavenLocal()
mavenRepo name: 'jboss-nexus', url: "http://repository.jboss.org/nexus/content/groups/public/"
mavenRepo name: "jboss-snapshots", url: "http://snapshots.jboss.org/maven2/"
}
dependencies {
classpath 'org.hibernate.build.gradle:gradle-maven-publish-auth:2.0.1'
}
}
repositories {
mavenCentral()
mavenLocal()
mavenRepo name: "jboss", url: "http://repository.jboss.org/nexus/content/groups/public/"
}
apply plugin: 'groovy'
apply plugin: 'maven-publish'
apply plugin: 'maven-publish-auth'
apply plugin: 'idea'
apply plugin: 'eclipse'
group = 'org.hibernate.build.gradle'
version = '1.0.0-SNAPSHOT'
buildDir = "target"
dependencies {
compile gradleApi()
compile localGroovy()
compile 'org.apache.ant:ant:1.8.2'
}
idea {
project {
languageLevel = '1.6'
}
module {
downloadSources = true
downloadJavadoc = true
}
}
publishing {
publications {
mavenJava(MavenPublication) {
from components.java
artifact sourcesJar {
classifier "sources"
}
pom.withXml {
// append additional metadata
asNode().children().last() + {
resolveStrategy = Closure.DELEGATE_FIRST
name 'Matrix Testing Plugin for Gradle'
description 'Gradle plugin for dynamic generation of Test tasks across a set of database profiles'
url 'http://hibernate.org'
organization {
name 'Hibernate.org'
url 'http://hibernate.org'
}
scm {
url 'http://github.com/hibernate/hibernate-matrix-testing'
connection 'scm:git:http://github.com/hibernate/hibernate-matrix-testing.git'
developerConnection 'scm:git:[email protected]:hibernate/hibernate-matrix-testing.git'
}
licenses {
license {
name 'GNU Lesser General Public License'
url 'http://www.gnu.org/licenses/lgpl-2.1.html'
comments 'See discussion at http://hibernate.org/license for more details.'
distribution 'repo'
}
}
developers {
developer {
id 'hibernate-team'
name 'The Hibernate Development Team'
organization 'Hibernate.org'
organizationUrl 'http://hibernate.org'
}
}
}
// TEMPORARY : currently Gradle Publishing feature is exporting dependencies as 'runtime' scope,
// rather than 'compile'; fix that.
asNode().dependencies[0].dependency.each {
it.scope[0].value = 'compile'
}
}
}
}
repositories {
maven {
if ( version.endsWith( 'SNAPSHOT' ) ) {
name 'jboss-snapshots-repository'
url 'https://repository.jboss.org/nexus/content/repositories/snapshots'
}
else {
name 'jboss-releases-repository'
url 'https://repository.jboss.org/nexus/service/local/staging/deploy/maven2/'
}
}
}
generatePomFileForMavenJavaPublication {
destination = file("$buildDir/generated-pom.xml")
}
}
task sourcesJar(type: Jar, dependsOn: compileJava) {
from sourceSets.main.allSource
classifier = 'sources'
}
task wrapper(type: Wrapper) {
gradleVersion = '1.6'
}