help-grub
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Multi-Boot depending of Key Commands


From: Jordan Uggla
Subject: Re: Multi-Boot depending of Key Commands
Date: Fri, 22 Mar 2013 12:56:43 -0700

On Tue, Mar 19, 2013 at 3:48 PM, Gonzalo Ruiz Panfilova
<address@hidden> wrote:
> My question is: Is there any way to boot to a different OS depending on wich
> key ('W', 'L' or 'F1') you press after booting the PC?

Yes. The menuentry command accepts a --hotkey option as documented
here: http://www.gnu.org/software/grub/manual/grub.html#menuentry .
Unfortunately there is no current way to add --hotkey options to the
menuentry commands generated by grub-mkconfig without editing
/etc/grub.d/10_linux, which I don't recommend doing as upgrades
provided by your distribution will eventually either replace this file
or fail to update it, either of which will eventually break things.
Instead I would recommend either writing your grub.cfg manually,
including the appropriate --hotkey option in your menu entries, or
creating a master grub.cfg which sets $default based on hotkeys before
using configfile to load your grub-mkconfig generated grub.cfg.
There's also likely a cleaner solution, and I will try to think about
it more and respond again if I come up with anything.

-- 
Jordan Uggla (Jordan_U on irc.freenode.net)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]