summaryrefslogtreecommitdiff
path: root/check-kernel.in
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2018-01-30 06:37:18 +0100
committerErich Eckner <git@eckner.net>2018-01-30 06:37:18 +0100
commit49fb8d278d84cf07390e2e2391b36d9984373e7a (patch)
tree3ab6a77a5476c12ad142bc13f1879f9d55580e22 /check-kernel.in
parent4ac0964ca972b003ac619cb49d1229de26f13902 (diff)
downloadcheck-kernel-49fb8d278d84cf07390e2e2391b36d9984373e7a.tar.xz
check-kernel.in: trim trailing .0s
Diffstat (limited to 'check-kernel.in')
-rw-r--r--check-kernel.in12
1 files changed, 12 insertions, 0 deletions
diff --git a/check-kernel.in b/check-kernel.in
index 9c2f2e4..b25b0c7 100644
--- a/check-kernel.in
+++ b/check-kernel.in
@@ -99,6 +99,18 @@ else
tail -n1
)
fi
+installed=$(
+ printf '%s\n' "${installed}" | \
+ sed '
+ s/\(\.0\)\+$//
+ '
+)
+running=$(
+ printf '%s\n' "${running}" | \
+ sed '
+ s/\(\.0\)\+$//
+ '
+)
if [ -z "${installed}" ] || \
[ "$(echo "${installed}" | wc -l)" -ne 1 ]; then