Summary

Feel proud that you now have your I can read badge for shell scripting. We have developed our scripts to be interactive and to prompt users for input during the script execution. These prompts can be used to simplify user operations on the command line. In this way, they do not need to remember the command-line options or have passwords that end up stored in the command-line history. When using passwords, we can simply store the value using the read -sp options.

Also, we saw how to pass options with and without values, and how to identify values correctly. We saw how to pass options and parameters at the same time, thanks to the double dash.

In the next chapter, we will take our time to look at the conditional statements in bash. ...

Get Mastering Linux Shell Scripting now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.