-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
76 lines (65 loc) · 2.25 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
plugins {
id "org.jetbrains.kotlin.jvm" version "1.8.21"
id 'com.github.johnrengelman.shadow' version '6.1.0'
}
apply plugin: 'java'
apply plugin: 'kotlin'
//Defines what version of Java to use.
sourceCompatibility = 1.8
//Defines how Kotlin should compile.
compileKotlin {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
kotlinOptions {
//Defines what jvm bytecode to use, 1.8 rather than 1.6
jvmTarget = "1.8"
apiVersion = "1.8"
languageVersion = "1.8"
}
}
//Defines how Kotlin should compile when testingTry to keep it the same as compileKotlin.
compileTestKotlin {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
kotlinOptions {
//Defines what jvm bytecode to use, 1.8 rather than 1.6
jvmTarget = "1.8"
apiVersion = "1.8"
languageVersion = "1.8"
}
}
repositories {
mavenLocal()
maven { url "https://s3-eu-west-1.amazonaws.com/furhat-maven/releases"}
maven { url 'https://repo.gradle.org/gradle/libs-releases' }
jcenter()
}
dependencies {
implementation 'com.furhatrobotics.furhatos:furhat-commons:+'
implementation 'io.github.sashirestela:simple-openai:3.8.2'
implementation 'com.furhatrobotics.assets:StandardLibraryCollection:1.2.0'
implementation 'com.fasterxml.jackson.module:jackson-module-kotlin:2.16.0'
}
jar {
def lowerCasedName = baseName.toLowerCase()
def normalizedName = lowerCasedName.substring(0,1).toUpperCase() + lowerCasedName.substring(1)
manifest.attributes(
'Class-Path': configurations.compileClasspath.collect { it.getName() }.join(' '),
'Main-Class': "furhatos.app.${lowerCasedName}.${normalizedName}Skill"
)
}
//ShadowJar depends on jar being finished properly.
shadowJar {
manifest {
exclude '**/Log4j2Plugins.dat'
exclude '**/node_modules'
}
Properties properties = new Properties()
properties.load(project.file('skill.properties').newDataInputStream())
def version = properties.getProperty('version')
def name = properties.getProperty('name')
archiveName = "${name}_${version}.skill"
from "skill.properties"
from "assets"
extension 'skill'
}