The OS is roughly divided into two areas, the kernel and the userland. The kernel provides the ability to manipulate the hardware. The shell acts as a bridge between the functions provided by the kernel. It is named like this because it ** wraps the kernel from the outside like a shell **.
Put together a file in advance of the operations you want the shell to perform. It's a script for the shell. In addition to the options and commands you want to use, write control syntax such as conditional branching, sequential execution, repetition, and subroutines (functions or programs that can be reused together) in a shell script.