From 7135f452dbca920b194fbb18f322283f528e6d21 Mon Sep 17 00:00:00 2001 From: Joe Date: Wed, 13 Apr 2011 21:25:56 +0100 Subject: Fixed bug were it complained about custom kernel just because the user is using the lts kernel. --- arch2parabola | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/arch2parabola b/arch2parabola index 9a1951b..1e88f1d 100755 --- a/arch2parabola +++ b/arch2parabola @@ -30,7 +30,7 @@ blacklist='http://repo.parabolagnulinux.org/docs/blacklist.txt' mirrorlist='http://repo.parabolagnulinux.org/files/mirrorlist' -kernel_pkgname='kernel26' +kernel_pkgnames=('kernel26' 'kernel26-lts') logfile="$(pwd)/arch2parabola-$$.log" @@ -120,7 +120,16 @@ Section 'Sanity check' exit 1 fi - if ! pacman -Q "$kernel_pkgname" > /dev/null 2>&1 + for name in ${kernel_pkgnames[@]} + do + if pacman -Q "${name}" > /dev/null 2>&1 + then + what_is_the_kernel="${name}" + break + fi + done + + if (( ! what_is_the_kernel )) then echo >&2 'The system is running a custom kernel.' echo >&2 'Please uninstall it before re-running this script.' -- cgit v1.2.2