[ipxe-devel] Entering String in menu-context possible?

Michael Brown mbrown at fensystems.co.uk
Mon Apr 15 13:28:05 UTC 2013


On 15/04/13 08:48, Leo Baltus wrote:
> Just a thought: would it make sense to have some sort of framework that
> allows several fields to be editted just like config and login and have
> config and login use that so that 'edit' could benefit from it too.
>
> I think it would be cool to be able to edit a few variables in one 'edit'
> session so you could visually edit for instance both kernel, initrd, and
> command-line options.

That's almost exactly why I'm wary of adding this feature: people will 
expect that ability.

Unfortunately, that wouldn't help in terms of byte count.  "config" and 
"login" already share the framework for edit boxes, which is abstracted 
out into editbox.c; there's no viable way I can see to share more code 
between these.

I'm happy to add an "edit" command which will create a single 
horizontally-scrollable edit box, which can be exited only via Enter, 
Ctrl-C, or Escape.  If this isn't going to be sufficient, then I'd 
rather not add the feature at all, and leave "read" as the only way to 
prompt the user for input.

Michael



More information about the ipxe-devel mailing list