Generate a menu from a list of items.

Synopsis

select NAME [in WORDS...]; do COMMANDS; done

Description

Display a numbered menu of WORDS and read the user's selection into NAME. Runs in the just-bash WASM shell inside SLICC.

Examples

$ select opt in "Option 1" "Option 2" "Quit"; do echo "Selected: $opt"; break; done

Present a menu and act on the selection.

Notes

Interactive selection may be limited in the SLICC environment.

See Also

case, for, read