3 ms·
20 years ago when Python was not pre-installed on most systems, the awk/gawk used to be my Swiss army knife. My first real programming job was translating 1000
by mynegation 9y ago
20 years ago when Python was not pre-installed on most systems, the awk/gawk used to be my Swiss army knife. My first real programming job was translating 1000 LOC awk program into C.
The syntax was simpler than ed, and getting combination of grep, uniq, cut etc correct.
I call it "Excel of the command line"
- dmd 9y agoIt's still extremely useful for those of us in industries where change comes veeerrrryyyy slooowwwly. For instance, most production servers I work with are still on Python 1.5.2 if they have Python at all - but awk, that I can depend on!
- ams6110 9y agoExcept is it gawk? The gnu enhanced awk is not universally installed, so for best portability stick with standard awk.
- dmd 9y agoAlmost certainly not!
- majewsky 9y agoAnd on the other end of the spectrum, it's becoming relevant again in container ops. A random container is not likely to have a Python, Ruby or even Perl, but if it has a shell, it most certainly also has an awk. Even Alpine has one in their busybox.