forked from ow2-proactive/jsr223-nativeshell
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
111 lines (86 loc) · 3.39 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
apply plugin: 'java'
apply plugin: 'maven'
apply from: "$rootDir/gradle/ext/coding-format.gradle"
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
// Configure the maven repository deployment
install {
repositories.mavenInstaller {
// Set the version
pom.version = project.version
// Set the group/namespace for the maven repository deployment.
pom.groupId = project.groupId
// Give the artifact a 'base name' (The version is added to the 'base name')
pom.artifactId = project.artifactId
}
}
buildscript {
repositories {
if (project.hasProperty('local')) mavenLocal()
mavenCentral()
maven { url 'http://repository.activeeon.com/content/groups/proactive/' }
maven { url "http://nexus.qmino.com/content/repositories/miredot" }
maven { url "https://plugins.gradle.org/m2/" }
}
dependencies {
classpath 'com.qmino:miredot-plugin:1.6.2'
classpath "com.diffplug.gradle.spotless:spotless:2.4.0"
classpath "org.ow2.proactive:coding-rules:1.0.0"
classpath "org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:2.2.1"
}
dependencies {
delete "gradle/ext"
ant.unjar src: configurations.classpath.find { it.name.startsWith("coding-rules") }, dest: 'gradle/ext'
}
}
allprojects {
apply plugin: 'maven'
group = 'jsr223.nativeshell'
version = project.version
rootProject.buildscript.repositories.each {
repositories.add(it)
}
// Upload the archives to the nexus repository. For execution, that needs to have
// the username and password set in the command line by -DnexusUsername=[username]
// and -DnexusPassword=[password]
uploadArchives {
repositories {
mavenDeployer {
// Set the version
pom.version = project.version
// Set the group/namespace for the maven repository deployment.
pom.groupId = project.groupId
// Give the artifact a 'base name' (The version is added to the 'base name')
pom.artifactId = project.artifactId
snapshotRepository(url: "http://repository.activeeon.com/content/repositories/snapshots/") {
authentication(userName: "${System.getProperty('nexusUsername')}",
password: "${System.getProperty('nexusPassword')}")
}
repository(url: "http://repository.activeeon.com/content/repositories/releases/") {
authentication(userName: "${System.getProperty('nexusUsername')}",
password: "${System.getProperty('nexusPassword')}")
}
}
}
}
}
ext.javaSubprojects = subprojects.findAll { new File(it.projectDir, "src").exists() }
task wrapper(type: Wrapper) {
gradleVersion = '3.3' //version required
}
configurations {
provided
}
sourceSets {
main {
main.compileClasspath += configurations.provided
test.compileClasspath += configurations.provided
test.runtimeClasspath += configurations.provided
}
}
dependencies {
provided 'org.ow2.proactive:scheduler-api:+'
testCompile group: 'junit', name: 'junit', version: '4.11'
testCompile group: 'commons-io', name: 'commons-io', version: '1.4'
testCompile 'org.ow2.proactive:scheduler-api:+'
}