help with bash scripting
Hello. I am currently attempting to write a script and I have bits and pieces of it working. I have a few questions regarding practices just to see if I am on the right track. I am new to scripting so you will have to bare with me.
both my question have to do with while statements:
1. I currently have if elfi fi statements within a single while statement. I am just wondering if this is ok to do? As in, will this cause me issues down the road? Or is it better to set it up another way?
2. If you have a while statement, and the purpose of the while statement is to validate user input, if the user inputs the correct information without trigger any errors the loop should end right? If the script stays in the loops, meaning a blank line with a flashing cursor just shows up instead what is supposed to come after the loops, what could be the cause of the loop not ending properly?
thanks in advance