[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How to remove variable from GRUB environment block
From: |
Andrey Borzenkov |
Subject: |
Re: How to remove variable from GRUB environment block |
Date: |
Tue, 12 Feb 2013 19:21:31 +0400 |
В Tue, 12 Feb 2013 14:57:53 +0100
Ulf Zibis <address@hidden> пишет:
> Am 12.02.2013 03:15, schrieb Andrey Borzenkov:
> > В Mon, 11 Feb 2013 20:52:12 +0100
> > Ulf Zibis <address@hidden> пишет:
> >
> >> Am 11.02.2013 17:46, schrieb Andrey Borzenkov:
> >>> For all practical purposes, empty variable is the same as non-existing
> >>> variable.
> >> Not really, testing for non-existence would fail.
> > How do you test for variable existence in grub?
>
> I'm not clearly sure, but I see different syntax in my grub.cfg, which I
> interpret as "test for
> existence":
>
No. Both just test whether result of variable substitution is empty or
not. It is empty if variable is not defined or if it is defined but
empty.
> if [ x"${feature_menuentry_id}" = xy ]; then
> ...
>
> if [ "${prev_saved_entry}" ]; then
> set saved_entry="${prev_saved_entry}"
> fi
>
>
> -Ulf
>