From 2207b79b73e62729b4136bfeed85bce510fabec5 Mon Sep 17 00:00:00 2001 From: Oliver Kopp Date: Thu, 14 Mar 2024 17:34:06 +0100 Subject: [PATCH] Fix log file path on Windows (#11028) --- src/main/java/org/jabref/Launcher.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/org/jabref/Launcher.java b/src/main/java/org/jabref/Launcher.java index a8926ae2e3e..8f1ea3229c7 100644 --- a/src/main/java/org/jabref/Launcher.java +++ b/src/main/java/org/jabref/Launcher.java @@ -140,7 +140,8 @@ private static void addLogToDisk() { "level", isDebugEnabled ? "debug" : "info", "writerFile", "rolling file", "writerFile.level", isDebugEnabled ? "debug" : "info", - "writerFile.file", directory.resolve("log_{date:yyyy-MM-dd_HH-mm-ss}.txt").toString(), + // We need to manually join the path, because ".resolve" does not work on Windows, because ":" is not allowed in file names on Windows + "writerFile.file", directory + File.separator + "log_{date:yyyy-MM-dd_HH-mm-ss}.txt", "writerFile.charset", "UTF-8", "writerFile.policies", "startup", "writerFile.backups", "30");