On Mon, Feb 21, 2011 at 7:59 PM, Matthew Gyurgyik
I know we (Dieter and I) chatted about using $supported_bootloaders for ask_option but I couldn't figure out any useful way to provide additional information next to the bootloader without creating an array like this. supported_bootloaders=(syslinux "some info" grub "some more info") which would seem to defeat the purpose of supported_bootloader.
i'm not sure 100% what all you have going on here, but i use a lot of
heredocs in these bash "data table" situations:
-----------------------------------------------------------------------
#!/bin/bash
key=none
val=none
echo -e "START\n[key] $key" "[val] $val\n"
process_opts () {
while IFS="=" read k v; do
# can't use key/val directly because
# last loop (EOF) will reset them!
key="$k" val="$v"
echo "[key] $key" "[val] $val"
done
}
process_opts <