Ok, dumb question: Is the link supposed to link to the actual book (i.e., is the book free and/or open source) or is this just a page of miscellaneous interesting links about the book (which we can pay for, later, when it's published). I was expecting the book, but the page itself says "This page is a placeholder for material related to the second edition of The AWK Programming Language." It's fine if this is a place…
The Awk Programming Language
131–140 of 159 posts
Re: The Awk Programming Language
#132Re: The Awk Programming Language
#133I was privileged to be one of the technical reviewers for this book. There's a fair bit of the original content (which is still great), but Kernighan's done a great job with some good restructuring and some significant updates, too. The early chapters are very hands-on, with something of a focus on "exploratory data processing", particularly with CSV files. Big data with AWK, you could say. Gawk and awk will soon hav…
It's not really a one-liner, neither something big, but one can take that as an example regarding that awk is really not just for one-liners.
Meanwhile having `--csv` support is really nice. I'd also like to see things like a builtin `length` function to be standard.
[1]: https://github.com/nvm-sh/nvm/ [2]: https://github.com/nvm-sh/nvm/pull/2827/ [3]: https://github.com/nvm-sh/nvm/blob/9a769630d7/nvm.sh#L1703-L...
Re: The Awk Programming Language
#134I was privileged to be one of the technical reviewers for this book. There's a fair bit of the original content (which is still great), but Kernighan's done a great job with some good restructuring and some significant updates, too. The early chapters are very hands-on, with something of a focus on "exploratory data processing", particularly with CSV files. Big data with AWK, you could say. Gawk and awk will soon hav…
Awk is really great, for those knowing nvm [1], I used awk to make `nvm ls-remote` run more than 10 times faster [2] by replacing the related shell script with around 60 lines of awk script [3], and I was quite happy with the improvement. It's not really a one-liner, neither something big, but one can take that as an example regarding that awk is really not just for one-liners. Meanwhile having `--csv` support is rea…
Re: The Awk Programming Language
#135Earlier quoted context omitted.
Visidata works with arbitrary separators. I just tried with a CSV separated with ␟ (ASCII unit separator) and it worked just fine.
Excel too?
Re: The Awk Programming Language
#1361. It is a lot faster than awk/perl/grep/sed combos
2. Way a lot readable and maintainable
3. More powerful than awk with it's string functionalities
4. Same availability as awk in OSs since last decade
Re: The Awk Programming Language
#137Earlier quoted context omitted.
Is there a particular benefit in writing a VM in AWK, placed in a big BEGIN block? Very similar code can be written in Perl or Python. Isn't the strength of AWK in its line-matching capability, being able to pattern-match a line against a block of code?
AWK runs everywhere . Perl and Python do not. Busybox has their own independent AWK implementation. https://busybox.net/ https://frippery.org/busybox/ Also see the first edition of the AWK manual online here: https://archive.org/details/pdfy-MgN0H1joIoDVoIC7
If we're counting minimalist implementations, there's micropython that even runs on microcontrollers that cost a less than 2 dollars.
Re: The Awk Programming Language
#138Awk was great at its time, but when you need at write more than 5 lines of awk code please consider using python since 1. It is a lot faster than awk/perl/grep/sed combos 2. Way a lot readable and maintainable 3. More powerful than awk with it's string functionalities 4. Same availability as awk in OSs since last decade
Re: The Awk Programming Language
#139I know lots of people like awk, but I pretend it doesn't exist. Why? Here's my comment on this from 6 years ago[0], >I used awk until I learned Python (long ago). For me, awk was yet another example of the "worse is better" approach to things so common in unix. For example, if you make a syntax error, you might get a message like "glob: exec error," rather than an informative message. "Worse is better" is probably a…
I will bet you $1000 that time spent learning Awk will lead to better results much faster than time spent polluting your privileged user directories with Python's excuse for "dependency management"
For many python users, it’s the only language they know. Often, they see programming in python, as part of their “identity” - so they’re overly invested in it, to the detriment of other wonderful languages, like awk.
I used to code perl myself, back in the day - but I came to appreciate the simplicity of awk, and now it’s one of my favourites. I no longer code perl, as a consequence, as I believe awk to be far more elegant! I wouldn’t have done so, if I was overly invested in being a “perl programmer”.
Re: The Awk Programming Language
#140Earlier quoted context omitted.
AWK runs everywhere . Perl and Python do not. Busybox has their own independent AWK implementation. https://busybox.net/ https://frippery.org/busybox/ Also see the first edition of the AWK manual online here: https://archive.org/details/pdfy-MgN0H1joIoDVoIC7
I'm sorry, where does Awk run but Perl and Python don't? If we're counting minimalist implementations, there's micropython that even runs on microcontrollers that cost a less than 2 dollars.