-
Notifications
You must be signed in to change notification settings - Fork 22
/
build.gradle
75 lines (55 loc) · 1.6 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
plugins {
id "java"
id "maven-publish"
id "com.github.node-gradle.node" version "7.0.1"
}
group 'org.polypheny'
description = 'The user interface for Polypheny-DB'
def versionMajor = 2
def versionMinor = 0
def versionQualifier = "-SNAPSHOT"
version = versionMajor + "." + versionMinor + versionQualifier
node {
version = '20.11.0'
//npmVersion = '6.14.11'
download = true
}
npmInstall.args = ['--package-lock', '--loglevel', 'warn']
npm_run_build.dependsOn(npmInstall)
jar.dependsOn(npm_run_build)
jar {
from 'dist' into 'webapp'
manifest {
attributes "Manifest-Version": "1.0"
attributes "Copyright": "The Polypheny Project"
attributes "Version": "$archiveVersion"
}
}
publishing {
publications {
"${project.name}"(MavenPublication) {
from components.java
pom {
licenses {
license {
name = 'Apache License, Version 2.0'
url = 'http://www.apache.org/licenses/LICENSE-2.0'
}
}
}
}
}
}
task generatePom(group: 'publishing', dependsOn: "generatePomFileFor${project.name.capitalize()}Publication")
task licenseReport(type: NpxTask) {
command = 'license-checker-rseidelsohn'
args = ['--json', '--production', '--files', 'build/reports/licenses/files', '--out', 'build/reports/licenses/licenseReport.json']
}
//clean.dependsOn(npm_cache_clean)
clean {
delete "/dist"
delete "/build"
delete "/node_modules"
}
// Add install task
task install(group: 'other', dependsOn: publishToMavenLocal)