-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
66 lines (52 loc) · 1.42 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
/*
* Master Gradle build script
*
* Depends on bndPlugin property set by settings.gradle.
* and bnd_* values from gradle.properties.
*/
import aQute.bnd.build.Workspace
import aQute.bnd.osgi.Constants
/* Add bnd gradle plugin as a script dependency */
buildscript {
repositories {
mavenCentral()
maven {
url "https://plugins.gradle.org/m2/"
}
}
dependencies {
classpath bndPlugin
classpath "com.moowork.gradle:gradle-node-plugin:1.1.1"
}
}
plugins {
id "com.moowork.gulp" version "1.1.1"
}
/* Initialize the bnd workspace */
Workspace.setDriver(Constants.BNDDRIVER_GRADLE)
Workspace.addGestalt(Constants.GESTALT_BATCH, null)
ext.bndWorkspace = new Workspace(rootDir, bnd_cnf).setOffline(gradle.startParameter.offline)
ext.cnf = rootProject.project(bnd_cnf)
/* Configure the subprojects */
subprojects {
def bndProject = bndWorkspace.getProject(name)
if (bndProject != null) {
plugins.apply 'biz.aQute.bnd'
plugins.apply 'com.moowork.gulp'
task gulpBuildWithOpts(type: GulpTask) {
doFirst { task ->
task.project.node {
nodeModulesDir = file("..")
}
task.project.gulp {
workDir = file("..")
}
args = ["build", "--module=${task.project.name}"]
}
}
processResources.dependsOn 'gulpBuildWithOpts'
}
}
task wrapper(type: Wrapper) {
jarFile = rootProject.file('.gradle-wrapper/gradle-wrapper.jar')
}