If you are the kind of person who never needs to do the same thing ever again, shell scripting is not for you. Others can greatly benefit, though, by grouping commands into plain text files called shell scripts.
Although it is entirely legit to type individual commands directly into the command line, putting them inside a file (then termed a script) perks up life at the shell in two ways: a) reusability of a large number of commands in one stroke, and b) reduced chances of operational error afforded by the file’s readability. This chapter hence introduces one of the fascinations of working ...