www.delorie.com/gnu/docs/gawk/gawk_191.html   search  
 
Buy the book!


The GNU Awk User's Guide

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

14.2 Reinventing Wheels for Fun and Profit

This section presents a number of POSIX utilities that are implemented in awk. Reinventing these programs in awk is often enjoyable, because the algorithms can be very clearly expressed, and the code is usually very concise and simple. This is true because awk does so much for you.

It should be noted that these programs are not necessarily intended to replace the installed versions on your system. Instead, their purpose is to illustrate awk language programming for "real world" tasks.

The programs are presented in alphabetical order.

14.2.1 Cutting out Fields and Columns  The cut utility.
14.2.2 Searching for Regular Expressions in Files  The egrep utility.
14.2.3 Printing out User Information  The id utility.
14.2.4 Splitting a Large File into Pieces  The split utility.
14.2.5 Duplicating Output into Multiple Files  The tee utility.
14.2.6 Printing Nonduplicated Lines of Text  The uniq utility.
14.2.7 Counting Things  The wc utility.


  webmaster   donations   bookstore     delorie software   privacy  
  Copyright 2003   by The Free Software Foundation     Updated Jun 2003