Advanced Topics in Shell Scripting
- This article focuses on more advanced topics in shell scripting including a number of common utilities which can help you write more versatile shell scripts.
You will often here these 3 tools talked about together. They are very useful for getting the output format of other programs into a format which is useful to you in a shell script. Awk is mainly used for splitting up text based around what is called a field separator (e.g. In “a:B:c:d” : is the field separator). Sed is used to alter the contents of a file or the output of a program in some way, its often used to remove unwanted output or to alter files. Grep is used to match patterns within its input or a file. Sed and grep both use a pattern matching language called regular expressions, more will be explained about these later on and additional references are available at the end of this tutorial.
Colin Sauze, 07/28/2005