This repository has been archived by the owner on Aug 8, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
121 lines (98 loc) · 2.92 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
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
buildscript {
repositories {
maven {
name = 'KotDis'
url = 'https://maven.kotlindiscord.com/repository/maven-public/'
}
}
dependencies {
classpath 'org.postgresql:postgresql:42.2.2'
}
}
plugins {
id 'application'
id 'maven-publish'
id 'com.github.johnrengelman.shadow' version '5.2.0'
id 'com.github.jakemarsden.git-hooks' version '0.0.1'
id 'io.gitlab.arturbosch.detekt' version '1.8.0'
id 'org.jetbrains.kotlin.jvm' version '1.3.72'
id "org.jetbrains.kotlin.kapt" version "1.3.61"
}
group 'com.kotlindiscord.database'
targetCompatibility = 1.11
version '1.0-SNAPSHOT'
repositories {
maven {
name = 'KotDis'
url = 'https://maven.kotlindiscord.com/repository/maven-public/'
}
}
def exposedVersion = "0.27.1"
dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8"
implementation "org.jetbrains.kotlin:kotlin-reflect:1.3.61"
api "org.jetbrains.exposed:exposed-core:$exposedVersion"
api "org.jetbrains.exposed:exposed-dao:$exposedVersion"
api "org.jetbrains.exposed:exposed-jdbc:$exposedVersion"
api "org.jetbrains.exposed:exposed-java-time:$exposedVersion"
api "org.postgresql:postgresql:42.2.2"
implementation 'info.picocli:picocli:4.2.0'
kapt 'info.picocli:picocli-codegen:4.2.0'
implementation 'net.oneandone.reflections8:reflections8:0.11.7'
// Logging dependencies
implementation 'ch.qos.logback:logback-classic:1.2.3'
implementation 'io.github.microutils:kotlin-logging:1.7.9'
implementation 'io.sentry:sentry-logback:1.7.30'
implementation 'org.codehaus.groovy:groovy:3.0.4' // For logback config
}
application {
mainClassName = "com.kotlindiscord.database.migrator.MigratorCliKt"
}
compileKotlin {
kotlinOptions.jvmTarget = "11"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "11"
}
detekt {
buildUponDefaultConfig = true
config = files("detekt.yml")
}
gitHooks {
hooks = ['pre-commit': 'detekt']
}
jar {
from sourceSets.main.kotlin
manifest {
attributes(
"Main-Class": "com.kotlindiscord.database.migrator.MigratorCliKt"
)
}
}
publishing {
repositories {
maven {
name = "KotDis"
url = uri("https://maven.kotlindiscord.com/repository/maven-snapshots/")
credentials {
username = project.findProperty("kotdis.user") ?: System.getenv("KOTLIN_DISCORD_USER")
password = project.findProperty("kotdis.password") ?: System.getenv("KOTLIN_DISCORD_PASSWORD")
}
version = project.version
}
}
publications {
maven(MavenPublication) {
from(components.java)
artifacts {
kotlinSourcesJar
}
}
}
}
kapt {
arguments {
arg("project", "${project.group}/${project.name}")
}
}
tasks.build.dependsOn tasks.shadowJar