-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathbuild.gradle
78 lines (66 loc) · 1.61 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
apply plugin: 'java'
apply plugin: 'maven'
repositories {
if (project.hasProperty('local')) {
mavenLocal()
}
mavenCentral()
maven {
url "https://plugins.gradle.org/m2/"
}
maven { url 'http://repository.activeeon.com/content/groups/proactive/'}
}
buildscript {
repositories {
maven {
url "https://plugins.gradle.org/m2/"
}
maven {
url "http://repository.activeeon.com/content/groups/proactive/"
}
}
dependencies {
}
}
group = 'org.ow2.proactive'
version = version
configurations {
localDeps
}
dependencies {
compile configurations.localDeps
}
clean.doFirst {
delete "${rootDir}/dist/"
delete "${rootDir}/env/"
delete "${rootDir}/proactive.egg-info"
delete "${rootDir}/__pycache__"
}
task copyDependenciesToLib(type: Copy) {
from configurations.localDeps
into "./proactive/java/lib"
}
task setup(type:Exec) {
if ( project.hasProperty("proactive_url") && project.hasProperty("username") && project.hasProperty("password") ) {
commandLine "./build.sh", "${proactive_url}", "${username}", "${password}"
}else{
commandLine "./build.sh", "", "", ""
}
}
task publish(type:Exec) {
ignoreExitValue true
try {
commandLine './publish.sh'
} catch (all) {
println 'the archive probably already exist so no need to publish twice'
}
}
task install(overwrite: true) {
}
task uploadArchives(overwrite: true) {
}
copyDependenciesToLib.dependsOn clean
setup.dependsOn copyDependenciesToLib
build.dependsOn setup
publish.dependsOn build
install.dependsOn publish