.. _shellscript: =================== Shell script basics =================== | A shell is the layer between you and the unix operating system, and provides easy access to unix commands. If you are new to shell programming, please read `How do I write a shell script? `_. | Popular basic text editors include 'gedit' (graphical interface), and 'nano' (curses-based interface). More advanced editors include 'vi' and 'emacs'. **Example** Below is an example of a simple shell script that prints the date, and then sleeps 20 seconds. #. Start a text editor:: $ nano #. Enter the following text, and save as 'simple.sh': | #!/bin/sh | date | sleep 20 #. Make the script executable:: $ chmod a+x simple.sh #. Run the command at the shell prompt:: $ ./simple.sh