From: Alexis Laferrière Date: Wed, 21 Feb 2018 17:28:52 +0000 (-0500) Subject: inkscape_tools: fix Inkscape version detection on Ubuntu X-Git-Url: http://nitlanguage.org inkscape_tools: fix Inkscape version detection on Ubuntu The regex detecting the Inkscape version was too permissive and expected 3 numbers. This make it wrongly match to the revision string on Ubuntu where the version string has 2 numbers: Inkscape 0.91 r13725 Reported-by: Romain Chanoir Signed-off-by: Alexis Laferrière --- diff --git a/contrib/inkscape_tools/src/svg_to_png_and_nit.nit b/contrib/inkscape_tools/src/svg_to_png_and_nit.nit index f660a31..b8a3157 100644 --- a/contrib/inkscape_tools/src/svg_to_png_and_nit.nit +++ b/contrib/inkscape_tools/src/svg_to_png_and_nit.nit @@ -220,7 +220,7 @@ var p = new ProcessReader("inkscape", "--version") var version_string = p.read_all p.wait p.close -var version_re = "([0-9]+\).([0-9]+\).[0-9]+".to_re +var version_re = "([0-9]+)\\.([0-9]+)".to_re var match = version_string.search(version_re) assert match != null var major = match[1]