Trying to understand the differences between the two functions gawk vs. awk? When would one use gawk vs awk? Or are they the same in terms of usage?
Also, could one provide an example?
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It only takes a minute to sign up.Sign up to join this community
nawk(“new awk”, an evolution of
oawk, the original UNIX implementation), used on *BSD and widely available on Linux;
mawk, a fast implementation that mostly sticks to standard features;
gawk, the GNU implementation, with many extensions;
If you only care about standard features, call
awk, which may be Gawk or nawk or mawk or some other implementation. If you want the features in GNU awk, use
gawk or Perl or Python.