From 4f2edf131882915b3f38e0850b29109b55d343d5 Mon Sep 17 00:00:00 2001 From: Alexandre Aubin Date: Sun, 1 Jul 2018 17:29:26 +0000 Subject: [PATCH] Improve ynh_version_gt helper (it doesn't properly rank the part after ~) --- scripts/_future.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/_future.sh b/scripts/_future.sh index 83a5313..1fa0e09 100644 --- a/scripts/_future.sh +++ b/scripts/_future.sh @@ -210,4 +210,4 @@ EOF chmod +x "/etc/cron.daily/node_update" } -ynh_version_gt() { test "$(printf '%s\n' "$@" | sort -V | head -n 1)" != "$1"; } +ynh_version_gt() { dpkg --compare-versions "$1" gt "$2" }