A generic question asker. Takes a question, an optional default answer, and, optionally, a list of valid replies. Returns the validated answer on stdout.
A wrapper for the shell 'select' command. Takes the name of an array containing the options. Adds a leading 'Quit' option. Returns the string 'idx=<number>' to be 'eval'd to set the variable 'idx' to the index of the chosen element. returns the string 'exit' with a return code of 1 if 'Quit' is chosen. Displays a title if the variable 'title' is set. It is very easy to produce complex hierarchical menus with this.