-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathbuild.gradle
More file actions
100 lines (88 loc) · 2.25 KB
/
build.gradle
File metadata and controls
100 lines (88 loc) · 2.25 KB
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
buildscript {
repositories {
maven {
url "https://plugins.gradle.org/m2/"
}
}
dependencies {
classpath 'io.spring.gradle:dependency-management-plugin:0.5.1.RELEASE'
}
}
group = 'org.vaadin.addons'
version = '0.0.3'
repositories {
mavenCentral()
maven {
url 'http://maven.vaadin.com/vaadin-addons'
}
mavenLocal()
}
apply plugin: 'io.spring.dependency-management'
apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'maven'
ext {
versions = [
'clara': '1.4.0'
]
}
dependencyManagement {
imports {
mavenBom 'io.spring.platform:platform-bom:1.1.1.RELEASE'
mavenBom 'com.vaadin:vaadin-bom:7.4.5'
}
}
dependencies {
compile 'com.vaadin:vaadin-server'
compile "org.vaadin.addons:clara:${project.versions.clara}"
compile 'org.springframework:spring-core'
compile 'org.springframework:spring-context'
compile 'org.springframework:spring-beans'
compile 'org.slf4j:slf4j-api'
testCompile 'junit:junit'
testCompile 'org.mockito:mockito-core'
testCompile 'org.springframework:spring-test'
testCompile 'org.slf4j:jcl-over-slf4j'
testCompile 'javax.servlet:javax.servlet-api'
}
compileJava {
sourceCompatibility = 1.7
targetCompatibility = 1.7
}
task writePom {
def pomFile = "$buildDir/pom/exported-pom.xml"
outputs.file(pomFile)
doFirst {
pom {
project {
inceptionYear '2015'
licenses {
license {
name 'The Apache Software License, Version 2.0'
url 'http://www.apache.org/licenses/LICENSE-2.0.txt'
distribution 'repo'
}
}
}
whenConfigured {
p -> p.dependencies = p.dependencies.findAll {
dep -> dep.scope != "test"
}
}
.withXml {
dependencyManagement.pomConfigurer.configurePom(asNode())
}
}.writeTo(pomFile)
}
}
jar {
dependsOn writePom
manifest.attributes "Implementation-Title": "Clara4Spring"
manifest.attributes "Implementation-Version": "$project.version"
manifest.attributes "Implementation-Vendor-Id": "Mark Koops"
manifest.attributes "Vaadin-Package-Version": 1
into ("META-INF/maven/$project.group/$project.name") {
from writePom.outputs
rename '.*', 'pom.xml'
}
}