-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsettings.gradle
More file actions
39 lines (31 loc) · 1.01 KB
/
settings.gradle
File metadata and controls
39 lines (31 loc) · 1.01 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
rootProject.name = 'SearchForest'
["comp", "test", "web", "server"].each {
def compDir = new File(rootDir, it)
if(!compDir.exists()){
compDir.mkdirs()
}
compDir.eachDir {subDir ->
def gradleFile = new File(subDir.absolutePath, "build.gradle")
if(!gradleFile.exists()){
gradleFile.text =
"""
dependencies {
}
""".stripIndent(20)
}
[
"src/main/java/com/searchforest",
"src/main/resources",
"src/test/java/com/searchforest",
"src/test/resources"
].each {srcDir->
def srcFolder = new File(subDir.absolutePath, srcDir)
if(!srcFolder.exists()){
srcFolder.mkdirs()
}
}
def projectName = ":${it}-${subDir.name}";
include projectName
project(projectName).projectDir = subDir
}
}