Shell Scripting: Automating Repetitive Tasks Through Simple, Logical Programs
A useful way to approach a scripting task is to write the required steps in plain language first. Identify the input, processing actions, expected output, and possible errors.