-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
139 lines (111 loc) · 3.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
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
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
buildscript {
ext.kotlin_version = '1.3.61'
ext.handlebars_version = '4.1.2'
ext.slf4j_version = '1.7.26'
ext.flexmark_version = '0.42.0'
ext.spek_version = '2.0.6'
ext.mockk_version = '1.9.3.kotlin12'
ext.picocli_version = '3.8.2'
ext.jansi_version = '1.17.1'
ext.snakeyaml_version = '1.23'
ext.bascule_lib_version = '0.0.21'
dependencies {
classpath "org.jetbrains.kotlin:kotlin-serialization:$kotlin_version"
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
plugins {
id 'org.jetbrains.kotlin.jvm' version '1.3.61'
id 'com.github.johnrengelman.shadow' version '4.0.3'
}
apply plugin: 'maven-publish'
apply plugin: 'kotlinx-serialization'
group 'org.liamjd'
version '0.0.21'
repositories {
mavenCentral()
jcenter()
mavenLocal()
}
dependencies {
compile "org.jetbrains.kotlin:kotlin-stdlib-jdk8"
compile group: 'org.jetbrains.kotlin', name: 'kotlin-reflect', version: "$kotlin_version"
compile group: 'org.jetbrains.kotlinx', name: 'kotlinx-coroutines-core', version: '1.0.1'
// bascule library
compile group: 'org.liamjd.bascule-lib', name: 'bascule-lib', version: "$bascule_lib_version"
// handlebars templating
compile group: 'com.github.jknack', name: 'handlebars', version: "$handlebars_version"
// markdown - probably want to be more selective with this!
compile group: 'com.vladsch.flexmark', name: 'flexmark-all', version: "$flexmark_version"
compile group: 'com.vladsch.flexmark', name: 'flexmark-ext-tables', version: "$flexmark_version"
// snakeyaml
compile group: 'org.yaml', name: 'snakeyaml', version: "$snakeyaml_version"
// sl4j logging
compile group: 'org.slf4j', name: 'slf4j-simple', version: "$slf4j_version"
compile 'io.github.microutils:kotlin-logging:1.6.26'
// command line parsing
compile group: 'info.picocli', name: 'picocli', version: "$picocli_version"
compile group: 'org.fusesource.jansi', name: 'jansi', version: "$jansi_version"
// Koin for Kotlin apps
compile 'org.koin:koin-core:1.0.0-RC-3'
// kotlinx serialization, for document caching
compile 'org.jetbrains.kotlinx:kotlinx-serialization-runtime:0.14.0'
// compile 'org.jetbrains.kotlinx:kotlinx-gradle-serialization-plugin:0.6.2'
// for console progress bar?
compile 'com.vdurmont:etaprinter:1.0.0'
// Testing
testCompile 'org.koin:koin-test:1.0.0-RC-3'
// testing
testCompile group: "org.jetbrains.kotlin", name: "kotlin-test", version: "$kotlin_version"
testImplementation "org.spekframework.spek2:spek-dsl-jvm:$spek_version"
testRuntimeOnly "org.spekframework.spek2:spek-runner-junit5:$spek_version"
testCompile group: "io.mockk", name: "mockk", version: "${mockk_version}"
}
test {
useJUnitPlatform {
includeEngines 'spek2'
}
}
compileKotlin {
kotlinOptions.jvmTarget = "1.8"
}
compileTestKotlin {
kotlinOptions.jvmTarget = "1.8"
}
sourceSets {
main.resources.srcDirs += ['src/main/resources']
test.resources.srcDirs += ['src/test/resources']
}
// deploy to maven local
publishing {
publications {
mavenJava(MavenPublication) {
from components.java
artifact sourceJar {
classifier "sources"
}
}
}
}
publishing {
repositories {
maven {
// change to point to your repo, e.g. http://my.org/repo
url "$buildDir/repo"
}
}
}
// configure shadowJar
shadowJar {
classifier = null
manifest {
attributes(
'Main-Class': 'org.liamjd.bascule.MainKt',
'Implementation-Title': 'Bascule static generator'
)
}
}
// building source jar
task sourceJar(type: Jar) {
from sourceSets.main.allJava
}