Originally posted by AnonymousCoward
View Post
Announcement
Collapse
No announcement yet.
Gawk 4.0 Is A Major New Release
Collapse
X
-
Yep, I think that's the key. If you are already using Perl on a regular basis then there's probably not much place for awk. If you are *not* using Perl regularly, however, and essentially have to "relearn from scratch" each time, then awk's size and simplicity are a real help.Test signature
Comment
-
Originally posted by AnonymousCoward View PostI really don't see the need for awk any longer. Whatever awk can do, perl can do better (or ruby or something), and it's been that way for ages. Just let it die already.
- Awk is POSIX. $dynamicLanguage is not. Portability is valued more highly in the domain of shell scripting and batch processing than many others. Hell even ed is still around and supposedly widely used in scripts though I haven't used it.
- You can formulate terse commands for interactive use in languages like Awk or Bash much better than in other languages especially when it comes to everyday sysadmin tasks. In Python if you want to do a simple task like open a FD, process some text with regex, and pipe the result to someplace else, you're already talking about importing at least 3 modules (probably sys, subprocess, and re), and either holding on to several temporary variables or writing several levels of nested lambdas on one really long line of code that you probably won't get right on the first try.
- Awk is actually pretty different from a general purpose language. I haven't used it in a long time and would have to re-learn most of it, but I remember I liked it and you can learn most of it in a day or two of work. It's quite similar to Gnu's Sed in that the general layout of a program consists of a bunch of pattern matching associated with functions you define. I hear Perl is similar but I've only really written one thing in Perl (CGI stuff) and it was a long time ago.
Comment
- Awk is POSIX. $dynamicLanguage is not. Portability is valued more highly in the domain of shell scripting and batch processing than many others. Hell even ed is still around and supposedly widely used in scripts though I haven't used it.
-
Comment