1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter-vps.git synced 2025-03-09 15:50:00 +00:00

Update to 4.14.77 kernel and fixes

This commit is contained in:
Ycarus (Yannick Chabanois) 2018-11-01 08:29:02 +00:00
parent 8b15c8a4f8
commit 91079cde73
3 changed files with 18 additions and 9 deletions

View file

@ -14,7 +14,9 @@ if [ -z "$(grep -m 1 vmlinuz $config_file | grep $kernel)" ]; then
while IFS= read ln
do
if [ -n "$(echo $ln | grep $kernel)" ]; then
sed -i "s@^\(GRUB_DEFAULT=\).*@\1\"$x\"@" $deflt_file
x=$(expr $x - 1)
sed -i "s@^\(GRUB_DEFAULT=\).*@\1\"1>$x\"@" $deflt_file
[ -f /boot/grub/grub.cfg ] && grub-mkconfig -o /boot/grub/grub.cfg >/dev/null 2>&1
exit 0
fi
x=$(expr $x + 1)