Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dependencies #3306

Merged
merged 3 commits into from
Jun 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@
"vscode": {
"extensions": [
"vscjava.vscode-gradle",
"GitHub.vscode-github-actions"
"GitHub.vscode-github-actions",
"astrizhachuk.1c-extension-pack",
"zhuangtongfa.Material-theme"
]
}
}
Expand Down
34 changes: 23 additions & 11 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import gradlegitproperties.org.ajoberstar.grgit.Grgit
import me.qoomon.gitversioning.commons.GitRefType
import org.apache.tools.ant.filters.EscapeUnicode
import java.util.*
import java.text.SimpleDateFormat

plugins {
`java-library`
Expand Down Expand Up @@ -50,9 +52,13 @@ gitVersioning.apply {
}
}

gitProperties {
customProperty("git.build.time", buildTime())
}

val isSnapshot = gitVersioning.gitVersionDetails.refType != GitRefType.TAG

val languageToolVersion = "6.1"
val languageToolVersion = "6.4"

dependencyManagement {
imports {
Expand All @@ -70,8 +76,8 @@ dependencies {
api("info.picocli:picocli-spring-boot-starter:4.7.6")

// lsp4j core
api("org.eclipse.lsp4j", "org.eclipse.lsp4j", "0.21.0")
api("org.eclipse.lsp4j", "org.eclipse.lsp4j.websocket.jakarta", "0.21.0")
api("org.eclipse.lsp4j", "org.eclipse.lsp4j", "0.23.1")
api("org.eclipse.lsp4j", "org.eclipse.lsp4j.websocket.jakarta", "0.23.1")

// 1c-syntax
api("io.github.1c-syntax", "bsl-parser", "0.24.0") {
Expand All @@ -95,19 +101,19 @@ dependencies {
implementation("org.languagetool", "language-ru", languageToolVersion)

// AOP
implementation("org.aspectj", "aspectjrt", "1.9.19")
implementation("org.aspectj", "aspectjrt", "1.9.22.1")

// commons utils
implementation("commons-io", "commons-io", "2.13.0")
implementation("org.apache.commons", "commons-lang3", "3.12.0")
implementation("commons-io", "commons-io", "2.16.1")
implementation("org.apache.commons", "commons-lang3", "3.14.0")
implementation("commons-beanutils", "commons-beanutils", "1.9.4"){
exclude("commons-logging", "commons-logging")
}
implementation("org.apache.commons", "commons-collections4", "4.4")
implementation("org.apache.commons", "commons-exec", "1.3")
implementation("org.apache.commons", "commons-exec", "1.4.0")

// progress bar
implementation("me.tongfei", "progressbar", "0.9.5")
implementation("me.tongfei", "progressbar", "0.10.1")

// (de)serialization
implementation("com.fasterxml.jackson.datatype:jackson-datatype-jsr310")
Expand All @@ -126,7 +132,7 @@ dependencies {
// CONSTRAINTS
implementation("com.google.guava:guava") {
version {
strictly("32.0.1-jre")
strictly("33.2.1-jre")
}
}

Expand All @@ -142,11 +148,11 @@ dependencies {

// test utils
testImplementation("org.jmockit", "jmockit", "1.49")
testImplementation("org.awaitility", "awaitility", "4.2.0")
testImplementation("org.awaitility", "awaitility", "4.2.1")
}

lombok {
version.set("edge-SNAPSHOT")
version.set("1.18.32")
}

jacoco {
Expand Down Expand Up @@ -385,3 +391,9 @@ nexusStaging {
tasks.withType<GenerateModuleMetadata> {
enabled = false
}

fun buildTime(): String {
val formatter = SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss'Z'")
formatter.timeZone = TimeZone.getTimeZone("UTC")
return formatter.format(Date())
}
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
import java.io.IOException;
import java.nio.charset.Charset;
import java.nio.file.Paths;
import java.time.Duration;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
Expand Down Expand Up @@ -83,14 +84,14 @@ private List<String> computeTestIds(DocumentContext documentContext) {
var getTestsCommand = new CommandLine(executable).addArguments(arguments, false);

var timeout = 10_000L;
var watchdog = new ExecuteWatchdog(timeout);
var watchdog = ExecuteWatchdog.builder().setTimeout(Duration.ofMillis(timeout)).get();

var outputStream = new ByteArrayOutputStream();
var streamHandler = new PumpStreamHandler(outputStream);

var resultHandler = new DefaultExecuteResultHandler();

var executor = new DefaultExecutor();
var executor = DefaultExecutor.builder().get();
executor.setWatchdog(watchdog);
executor.setStreamHandler(streamHandler);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,7 @@
import org.antlr.v4.runtime.Token;
import org.apache.commons.lang3.StringUtils;
import org.languagetool.JLanguageTool;
import org.languagetool.language.AmericanEnglish;
import org.languagetool.language.Russian;
import org.languagetool.Languages;
import org.languagetool.rules.RuleMatch;

import java.io.IOException;
Expand Down Expand Up @@ -68,8 +67,8 @@ public class TypoDiagnostic extends AbstractDiagnostic {

@Getter(lazy = true, value = AccessLevel.PRIVATE)
private static final Map<String, JLanguageToolPool> languageToolPoolMap = Map.of(
"en", new JLanguageToolPool(new AmericanEnglish()),
"ru", new JLanguageToolPool(new Russian())
"en", new JLanguageToolPool(Languages.getLanguageForShortCode("en-US")),
"ru", new JLanguageToolPool(Languages.getLanguageForShortCode("ru"))
);

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ void initialize() throws ExecutionException, InterruptedException {
// given
InitializeParams params = new InitializeParams();

WorkspaceFolder workspaceFolder = new WorkspaceFolder(Absolute.path(PATH_TO_METADATA).toUri().toString());
WorkspaceFolder workspaceFolder = new WorkspaceFolder(Absolute.path(PATH_TO_METADATA).toUri().toString(), "test");
List<WorkspaceFolder> workspaceFolders = List.of(workspaceFolder);
params.setWorkspaceFolders(workspaceFolders);

Expand All @@ -82,7 +82,7 @@ void initializeRename() throws ExecutionException, InterruptedException {
// given
InitializeParams params = new InitializeParams();

WorkspaceFolder workspaceFolder = new WorkspaceFolder(Absolute.path(PATH_TO_METADATA).toUri().toString());
WorkspaceFolder workspaceFolder = new WorkspaceFolder(Absolute.path(PATH_TO_METADATA).toUri().toString(), "test");
List<WorkspaceFolder> workspaceFolders = List.of(workspaceFolder);
params.setWorkspaceFolders(workspaceFolders);

Expand Down
Loading