-
Notifications
You must be signed in to change notification settings - Fork 2
/
build.gradle
90 lines (76 loc) · 2.45 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
79
80
81
82
83
84
85
86
87
88
89
90
import java.text.SimpleDateFormat
plugins {
id 'application'
id 'net.nemerosa.versioning' version '2.15.0'
// https://plugins.gradle.org/plugin/net.nemerosa.versioning
}
group = 'io.questdb.desktop'
version = '1.0.0'
description = 'Desktop user interface to QuestDB through the Postgres Wire Protocol.'
repositories {
mavenCentral()
}
java {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
dependencies {
implementation 'org.questdb:questdb:7.3.2'
implementation 'org.postgresql:postgresql:42.6.0'
implementation 'com.google.code.gson:gson:2.10.1'
implementation 'org.realityforge.org.jetbrains.annotations:org.jetbrains.annotations:1.7.0'
testImplementation 'org.junit.jupiter:junit-jupiter:5.8.2'
testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.8.2'
testRuntimeOnly 'org.junit.platform:junit-platform-commons:1.8.2'
testImplementation 'org.hamcrest:hamcrest:2.2'
testImplementation 'org.mockito:mockito-core:4.3.1'
}
application {
mainClass = 'io.questdb.desktop.Main'
applicationDefaultJvmArgs = ['-Xmx2G', '-Xms2G', '-server', '-Dfile.encoding=UTF-8']
}
jar {
manifest {
attributes(
'Main-Class': 'io.questdb.desktop.Main',
'Build-Timestamp': new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSZ").format(new Date()),
'Build-Branch': versioning.info.branch,
'Build-Revision': versioning.info.commit,
'Build-Jdk': "${System.properties['java.version']} (${System.properties['java.vendor']} ${System.properties['java.vm.version']})"
)
}
}
distributions.main {
contents {
from startScripts
}
}
startScripts {
startScripts.applicationName = 'start-client'
doLast {
def windowsScriptFile = file getWindowsScript()
def unixScriptFile = file getUnixScript()
windowsScriptFile.text = windowsScriptFile.text.replace('set APP_HOME=%DIRNAME%..', 'set APP_HOME=%DIRNAME%')
unixScriptFile.text = unixScriptFile.text.replace('APP_HOME=$( cd "${APP_HOME:-./}.." && pwd -P ) || exit', 'APP_HOME=$(pwd -P) || exit')
}
}
distZip {
eachFile { file ->
if (file.path.contains('bin')) {
file.exclude()
}
}
}
distTar {
eachFile { file ->
if (file.path.contains('bin')) {
file.exclude()
}
}
}
test {
useJUnitPlatform()
}
wrapper {
gradleVersion = '8.3'
}