Quick Guide to nawk
nawk (new awk) extends the original awk with more built-in functions, better string handling, and user-defined functions. Most modern systems have both installed; nawk is generally preferred. This guide covers syntax, built-in variables, patterns, string functions, control flow, arrays, and common one-liners.
Note: This guide was originally published in 2006 and has been substantially expanded in May 2026 with full content, with assistance from Claude (Anthropic).
See Also — Other Quick Guides
Quick guide to n8n | Quick guide to NSCC ASPIRE2A | Quick guide to Docker | Quick guide to CVS | Quick guide to GNUPlot | Quick guide to Emacs | Quick guide to Git
For the full specification, see the GNU awk manual. On most Linux systems, man nawk or man awk also gives a concise reference.
Leave a comment