chore: cleaned up build.gradle, updated glue

This commit is contained in:
zaaarf 2024-09-25 18:52:38 +02:00
parent b486c2c581
commit 73dfda2d1c
No known key found for this signature in database
GPG key ID: 102E445F4C3F829B
2 changed files with 4 additions and 13 deletions

View file

@ -1,12 +1,11 @@
plugins {
id 'java'
id 'org.jetbrains.intellij.platform' version '2.0.1'
id 'com.github.johnrengelman.shadow' version '8.1.1'
id 'com.palantir.git-version' version '3.1.0'
}
group = 'mp.code'
//version = versionDetails().lastTag
version = versionDetails().lastTag
java {
sourceCompatibility = targetCompatibility = JavaVersion.VERSION_17
@ -23,7 +22,7 @@ repositories {
dependencies {
implementation 'org.slf4j:slf4j-api:2.0.9'
implementation 'ch.qos.logback:logback-classic:1.4.12'
implementation files('../../lib/dist/java/build/libs/codemp-0.6.2.jar')
implementation 'mp.code:codemp:0.7.0:linux-x86_64'
compileOnly 'org.projectlombok:lombok:1.18.34'
annotationProcessor 'org.projectlombok:lombok:1.18.34'
@ -36,13 +35,6 @@ dependencies {
}
}
shadowJar {
archiveClassifier.set('')
dependencies {
include(dependency(files('../../lib/java/build/libs/codemp-0.6.2.jar')))
}
}
tasks {
patchPluginXml {
sinceBuild.set('222')
@ -62,5 +54,3 @@ tasks {
// useful for debugging
runIde.doFirst { environment 'RUST_BACKTRACE', 'full' }
build.dependsOn shadowJar

View file

@ -6,6 +6,7 @@ import com.google.common.collect.Maps;
import com.intellij.openapi.editor.markup.RangeHighlighter;
import mp.code.Extensions;
import mp.code.Workspace;
import mp.code.data.Config;
import mp.code.exceptions.ConnectionException;
import mp.code.intellij.exceptions.ide.NotConnectedException;
import mp.code.Client;
@ -26,7 +27,7 @@ public class CodeMP {
public static final Map<String, RangeHighlighter> HIGHLIGHTER_MAP = new ConcurrentHashMap<>();
public static void connect(String username, String password) throws ConnectionException {
CLIENT = Client.connectToServer(username, password, "api.codemp.dev", 50053, false); // TODO don't hardcode
CLIENT = Client.connect(new Config(username, password, "api.codemp.dev", 50053, false)); // TODO don't hardcode
new Thread(() -> Extensions.drive(true)).start();
}