Here is a sample output of your script. The $ is the shell prompt. The items in italics are not part of the sample outpu
Posted: Fri Jul 08, 2022 6:16 am
The variable name of the setting is: EDITOR The variable value of the setting is: Invalid setting. (Hint: To retrieve a variable name before the "=" sign, research the expr command's ability in handling strings) Enter setting (format: ABCD=abcd): =vi (user input) The variable name of the setting is: The variable value of the setting is: vi Invalid setting. Enter setting (format: ABCD=abcd): 1EDITOR=vi (user input) The variable name of the setting is: 1EDITOR The variable e of the setting is: vi Invalid setting. The first character of a variable name cannot be a digit. Enter setting (format: ABCD=abcd): EDITOR=vi (user input) The variable name of the setting is: EDITOR The variable value of the setting is: vi New setting added. *** MENU *** 1. Add a Setting 2. Delete a Setting 3. View a Setting 4. View All Settings Q - Quit CHOICE: 1 (user input) Enter setting (format: ABCD=abcd): USER=jchen (user input) The variable name of the setting is: USER The variable value of the setting is: jchen Variable exists. Changing the values of existing variables is not allowed.