grub2 and Previous Linux versions submenu
Christoph Mathys
eraserix at gmail.com
Mon Apr 16 07:00:53 UTC 2012
On Fri, Apr 13, 2012 at 1:39 PM, Colin Watson <cjwatson at ubuntu.com> wrote:
> Indeed; sorry about that. This patch would do it.
Thank you both. This does exactly what I had in mind. Below an updated
patch that applies cleanly to my current 10_linux:
--- 10_linux.orig 2012-04-16 08:51:36.061262852 +0200
+++ 10_linux 2012-04-16 08:52:48.881262843 +0200
@@ -194,7 +194,6 @@
if [ "\$linux_gfx_mode" != "text" ]; then load_video; fi
EOF
-in_submenu=false
while [ "x$list" != "x" ] ; do
linux=`version_find_latest $list`
echo "Found linux image: $linux" >&2
@@ -253,13 +252,4 @@
fi
list=`echo $list | tr ' ' '\n' | grep -vx $linux | tr '\n' ' '`
-
- if [ "$list" ] && ! $in_submenu; then
- echo "submenu \"Previous Linux versions\" {"
- in_submenu=:
- fi
done
-
-if $in_submenu; then
- echo "}"
-fi
Christoph
More information about the Ubuntu-devel-discuss
mailing list