-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
38 lines (31 loc) · 1.07 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
task ngUpdate(type: Exec) {
executable 'docker'
args 'run', '--rm', '-v', "${projectDir}/webapp:/app", 'trion/ng-cli:10.2.0', 'ng', 'update'
outputs.dir "${projectDir}/webapp/node_modules"
}
task npmInstall(type: Exec) {
executable 'docker'
args 'run', '--rm', '-v', "${projectDir}/webapp:/app", 'trion/ng-cli:10.2.0', 'npm', 'install'
outputs.dir "${projectDir}/webapp/node_modules"
}
task angularBuild(type: Exec) {
executable 'docker'
args 'run', '--rm', '-v', "${projectDir}/webapp:/app", 'trion/ng-cli:10.2.0', 'ng', 'build'
outputs.dir "${projectDir}/webapp/dist"
dependsOn npmInstall
}
task build {
dependsOn angularBuild
}
task uninstallTypescript (type: Exec) {
executable 'docker'
args 'run', '--rm', '-v', "${projectDir}/webapp:/app", 'trion/ng-cli:10.2.0', 'npm', 'uninstall', 'typescript'
}
task installTypescript (type: Exec) {
executable 'npm'
args 'run', '--rm', '-v', "${projectDir}/webapp:/app", 'trion/ng-cli:10.2.0', 'npm', 'install', '--save-dev', '[email protected]'
dependsOn uninstallTypescript
}
task typescript {
dependsOn installTypescript
}