Marc Kupietz | 4f6ed42 | 2024-03-01 07:27:46 +0100 | [diff] [blame] | 1 | /* |
| 2 | * This file was generated by the Gradle 'init' task. |
| 3 | * |
| 4 | * This generated file contains a sample Kotlin application project to get you started. |
| 5 | * For more details take a look at the 'Building Java & JVM projects' chapter in the Gradle |
| 6 | * User Manual available at https://docs.gradle.org/7.4.2/userguide/building_java_projects.html |
| 7 | */ |
| 8 | |
| 9 | |
| 10 | plugins { |
| 11 | // Apply the org.jetbrains.kotlin.jvm Plugin to add support for Kotlin. |
Marc Kupietz | 3947571 | 2024-03-01 12:38:05 +0100 | [diff] [blame] | 12 | id 'org.jetbrains.kotlin.jvm' version '2.0.0-Beta4' |
Marc Kupietz | 4f6ed42 | 2024-03-01 07:27:46 +0100 | [diff] [blame] | 13 | |
| 14 | // Apply the application plugin to add support for building a CLI application in Java. |
| 15 | id 'application' |
Marc Kupietz | 1b59599 | 2024-03-01 14:54:30 +0100 | [diff] [blame] | 16 | id 'com.github.johnrengelman.shadow' version '8.1.1' |
Marc Kupietz | 3112236 | 2024-03-02 11:13:37 +0100 | [diff] [blame] | 17 | id ("org.jetbrains.kotlin.kapt") version "2.0.0-Beta4" |
Marc Kupietz | 4f6ed42 | 2024-03-01 07:27:46 +0100 | [diff] [blame] | 18 | } |
| 19 | |
Marc Kupietz | 4f6ed42 | 2024-03-01 07:27:46 +0100 | [diff] [blame] | 20 | repositories { |
Marc Kupietz | 4f6ed42 | 2024-03-01 07:27:46 +0100 | [diff] [blame] | 21 | mavenCentral() |
Marc Kupietz | 56a4556 | 2024-03-20 20:18:08 +0100 | [diff] [blame] | 22 | maven { url 'https://jitpack.io' } |
Marc Kupietz | 4f6ed42 | 2024-03-01 07:27:46 +0100 | [diff] [blame] | 23 | } |
| 24 | |
| 25 | dependencies { |
| 26 | // Align versions of all Kotlin components |
| 27 | implementation platform('org.jetbrains.kotlin:kotlin-bom') |
| 28 | |
| 29 | // Use the Kotlin JDK 8 standard library. |
| 30 | implementation 'org.jetbrains.kotlin:kotlin-stdlib' |
Marc Kupietz | 6181f22 | 2024-03-12 16:59:59 +0100 | [diff] [blame] | 31 | implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-core:1.8.0' |
Marc Kupietz | 4f6ed42 | 2024-03-01 07:27:46 +0100 | [diff] [blame] | 32 | |
| 33 | // This dependency is used by the application. |
| 34 | implementation 'com.google.guava:guava:33.0.0-jre' |
| 35 | |
Marc Kupietz | 3112236 | 2024-03-02 11:13:37 +0100 | [diff] [blame] | 36 | |
| 37 | kapt("info.picocli:picocli-codegen:4.7.5") |
| 38 | implementation ("info.picocli:picocli:4.7.5") |
| 39 | |
Marc Kupietz | 4f6ed42 | 2024-03-01 07:27:46 +0100 | [diff] [blame] | 40 | // Use the Kotlin test library. |
| 41 | testImplementation 'org.jetbrains.kotlin:kotlin-test' |
| 42 | |
| 43 | // Use the Kotlin JUnit integration. |
| 44 | testImplementation 'org.jetbrains.kotlin:kotlin-test-junit' |
Marc Kupietz | 3947571 | 2024-03-01 12:38:05 +0100 | [diff] [blame] | 45 | testImplementation "org.jetbrains.kotlin:kotlin-test:2.0.0-Beta4" |
Marc Kupietz | 0c6e877 | 2024-03-19 07:03:07 +0100 | [diff] [blame] | 46 | |
Marc Kupietz | 56a4556 | 2024-03-20 20:18:08 +0100 | [diff] [blame] | 47 | implementation 'com.github.kupietz:cistern:v1.0.2' |
Marc Kupietz | 4f6ed42 | 2024-03-01 07:27:46 +0100 | [diff] [blame] | 48 | } |
| 49 | |
| 50 | |
| 51 | application { |
| 52 | // Define the main class for the application. |
Marc Kupietz | 1b59599 | 2024-03-01 14:54:30 +0100 | [diff] [blame] | 53 | mainClass = 'de.ids_mannheim.korapxmltools.KorapXml2ConlluKt' |
Marc Kupietz | 4f6ed42 | 2024-03-01 07:27:46 +0100 | [diff] [blame] | 54 | } |
| 55 | |
| 56 | jar { |
| 57 | // Will include every single one of your dependencies, project or not |
Marc Kupietz | fb0a2ca | 2024-03-01 12:38:05 +0100 | [diff] [blame] | 58 | // def lowerCasedName = baseName.toLowerCase() |
| 59 | // def normalizedName = lowerCasedName.substring(0,1).toUpperCase() + lowerCasedName.substring(1) |
Marc Kupietz | 4f6ed42 | 2024-03-01 07:27:46 +0100 | [diff] [blame] | 60 | |
| 61 | manifest.attributes( |
| 62 | 'Class-Path': configurations.compileClasspath.collect { it.getName() }.join(' '), |
Marc Kupietz | 1b59599 | 2024-03-01 14:54:30 +0100 | [diff] [blame] | 63 | 'Main-Class': "de.ids_mannheim.korapxmltools.KorapXml2ConlluKt" |
Marc Kupietz | 4f6ed42 | 2024-03-01 07:27:46 +0100 | [diff] [blame] | 64 | ) |
Marc Kupietz | 1b59599 | 2024-03-01 14:54:30 +0100 | [diff] [blame] | 65 | shadowJar { |
| 66 | archiveBaseName.set('korapxml2conllu') |
| 67 | archiveClassifier.set('') |
| 68 | archiveVersion.set('') |
| 69 | } |
Marc Kupietz | 4f6ed42 | 2024-03-01 07:27:46 +0100 | [diff] [blame] | 70 | } |
| 71 | |
| 72 | |
| 73 | configurations { |
| 74 | runtimeLib.extendsFrom implementation |
| 75 | } |