Quoting Robert Millan <r...@aybabtu.com>:
+ saved_entry=\${chosen_entry}
+ save_env saved_entry
EOF
prepare_grub_to_access_device ${GRUB_DEVICE_BOOT} | sed -e "s/^/\t/"
cat << EOF
I think it'd really be a good idea to either factorize this into a function
(ala prepare_grub_to_access_device), or make it part of the scripting engine.
I already mentioned the possibility of having an argument to save_env
to allow saving a variable under a different name, e.g.:
save_env --as saved_entry chosen_entry
Another approach would be to allow saving text from the command line:
save_env saved_entry="$chosen_entry"
I'm afraid of the possibility that later we want to change something
and can't
because 3rd party scripts depend on it (this happened with disk selection
before we had prepare_grub_to_access_device).
I think we would want to use text, not numbers. We have enough space
in the environment for that. It's more reliable.
--
Regards,
Pavel Roskin
_______________________________________________
Grub-devel mailing list
Grub-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/grub-devel