From 892dd6c8e94b73f3c0e793b73f12b446b294f6f6 Mon Sep 17 00:00:00 2001 From: Arnaud Roques Date: Mon, 22 May 2023 18:48:42 +0200 Subject: [PATCH] fix: improve pipemap option https://github.com/plantuml/plantuml/issues/1429 --- gradle.properties | 2 +- src/net/sourceforge/plantuml/Pipe.java | 8 +++++--- .../plantuml/timingdiagram/command/TimeTickBuilder.java | 2 +- src/net/sourceforge/plantuml/version/Version.java | 2 +- 4 files changed, 8 insertions(+), 6 deletions(-) diff --git a/gradle.properties b/gradle.properties index 98e9dffbc..570627a5e 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,4 +1,4 @@ # Warning, "version" should be the same in gradle.properties and Version.java # Any idea anyone how to magically synchronize those :-) ? -version = 1.2023.8 +version = 1.2023.9beta1 org.gradle.workers.max = 3 \ No newline at end of file diff --git a/src/net/sourceforge/plantuml/Pipe.java b/src/net/sourceforge/plantuml/Pipe.java index 41f59c76b..419007d49 100644 --- a/src/net/sourceforge/plantuml/Pipe.java +++ b/src/net/sourceforge/plantuml/Pipe.java @@ -53,6 +53,7 @@ import net.sourceforge.plantuml.core.DiagramDescription; import net.sourceforge.plantuml.error.PSystemError; import net.sourceforge.plantuml.preproc.Defines; import net.sourceforge.plantuml.security.SFile; +import net.sourceforge.plantuml.url.CMapData; public class Pipe { // ::remove file when __CORE__ @@ -124,9 +125,10 @@ public class Pipe { // https://forum.plantuml.net/10049/2019-pipemap-diagrams-containing-links-give-zero-exit-code // We don't check errors error.goOk(); - if (result == null) - ps.println(); - else + if (result == null) { + final CMapData empty = new CMapData(); + ps.println(empty.asString("plantuml")); + } else ps.println(result); } diff --git a/src/net/sourceforge/plantuml/timingdiagram/command/TimeTickBuilder.java b/src/net/sourceforge/plantuml/timingdiagram/command/TimeTickBuilder.java index 5e2723bba..f7db09e78 100644 --- a/src/net/sourceforge/plantuml/timingdiagram/command/TimeTickBuilder.java +++ b/src/net/sourceforge/plantuml/timingdiagram/command/TimeTickBuilder.java @@ -50,7 +50,7 @@ public class TimeTickBuilder { public static IRegex expressionAtWithoutArobase(String name) { return new RegexOr( // - new RegexLeaf(name + "CODE", ":([%pLN_.]+)([-+]\\d+)?"), // + new RegexLeaf(name + "CODE", ":([%pLN_.]+)([-+][.\\d]+)?"), // new RegexLeaf(name + "DATE", "(\\d+)/(\\d+)/(\\d+)"), // new RegexLeaf(name + "HOUR", "(\\d+):(\\d+):(\\d+)"), // new RegexLeaf(name + "DIGIT", "(\\+?)(-?\\d+\\.?\\d*)"), // diff --git a/src/net/sourceforge/plantuml/version/Version.java b/src/net/sourceforge/plantuml/version/Version.java index 3c0fa9e9e..bd7aa5803 100644 --- a/src/net/sourceforge/plantuml/version/Version.java +++ b/src/net/sourceforge/plantuml/version/Version.java @@ -46,7 +46,7 @@ public class Version { // Warning, "version" should be the same in gradle.properties and Version.java // Any idea anyone how to magically synchronize those :-) ? - private static final String version = "1.2023.8"; + private static final String version = "1.2023.9beta1"; public static String versionString() { return version;