Skip to content

Commit 43f9ba4

Browse files
build: convert build.gradle from groovy to kotlin and add toml catalog
1 parent 7331c15 commit 43f9ba4

File tree

3 files changed

+79
-91
lines changed

3 files changed

+79
-91
lines changed

build.gradle

Lines changed: 0 additions & 91 deletions
This file was deleted.

build.gradle.kts

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
/*
2+
* Copyright (c) 2023. Smart Operating Block
3+
*
4+
* Use of this source code is governed by an MIT-style
5+
* license that can be found in the LICENSE file or at
6+
* https://opensource.org/licenses/MIT.
7+
*/
8+
9+
plugins {
10+
application
11+
java
12+
eclipse
13+
}
14+
15+
group = "io.github.smartoperatingblock"
16+
17+
repositories {
18+
mavenCentral()
19+
maven {
20+
url = uri("https://raw.githubusercontent.com/jacamo-lang/mvn-repo/master")
21+
}
22+
maven {
23+
url = uri("https://repo.gradle.org/gradle/libs-releases")
24+
}
25+
}
26+
27+
dependencies {
28+
implementation(libs.jacamo)
29+
testImplementation(libs.junit.api)
30+
testRuntimeOnly(libs.junit.engine)
31+
}
32+
33+
tasks.withType<Test> {
34+
useJUnitPlatform()
35+
}
36+
37+
java {
38+
toolchain {
39+
languageVersion.set(JavaLanguageVersion.of(15))
40+
}
41+
}
42+
43+
sourceSets.getByName("main") {
44+
java.srcDir("src/env")
45+
java.srcDir("src/agt")
46+
java.srcDir("src/org")
47+
java.srcDir("src/int")
48+
java.srcDir("src/java")
49+
resources.srcDir("src/resources")
50+
}
51+
52+
tasks.named<JavaExec>("run") {
53+
dependsOn("classes")
54+
group = "JaCaMo"
55+
description = "runs the JaCaMo application"
56+
doFirst {
57+
mkdir("log")
58+
}
59+
mainClass.set("jacamo.infra.JaCaMoLauncher")
60+
args("automation_management_microservice.jcm")
61+
classpath = project.sourceSets.main.get().runtimeClasspath
62+
}
63+
64+
tasks.named("clean") {
65+
delete("bin")
66+
buildDir.deleteRecursively()
67+
delete("log")
68+
}

gradle/libs.versions.toml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
[versions]
2+
junit = "5.8.1"
3+
4+
[libraries]
5+
jacamo = { module = "org.jacamo:jacamo", version = "1.1" }
6+
junit-api = { module = "org.junit.jupiter:junit-jupiter-api", version.ref = "junit" }
7+
junit-engine = { module = "org.junit.jupiter:junit-jupiter-engine", version.ref = "junit" }
8+
9+
[bundles]
10+
11+
[plugins]

0 commit comments

Comments
 (0)