4 ms·
I really don't think so! If you have experience with any scripting, you can fully grok the fundamentals of awk in 1 hour. You might not memorize all the nuances
by j0hnyl 4y ago
I really don't think so! If you have experience with any scripting, you can fully grok the fundamentals of awk in 1 hour. You might not memorize all the nuances, but you can establish the fundamentals to a degree that most things you would try to achieve would take just a few minutes of brushing up.
For those that haven't taken the time yet, I think this is a good place to start:
https://learnxinyminutes.com/docs/awk/ https://learnxinyminutes.com/docs/awk/
Of course, some people do very advanced things in awk and I absolutely agree that 1 hour of study isn't going to make you a ninja, but it's absolutely enough to learn the awk programming paradigm so that when the need arises you can quickly mobilize the solution you need.
For example: If you're quick to the draw, it can take less time to write an awk one liner to calculate the average of a column in a csv than it does to copy the csv into excel and highlight the column. It's a massive productivity booster.
- 2devnull 4y agoI feel like I do this every three years then proceed to never use it. Then I read a post on hn and think about how great it could be; rinse and repeat
- boredtofears 4y agoyeah thats exactly right. it may only take an hour to learn, but every time i need to use awk it seems like i have to spend an hour to re-learn its goofy syntax.
- tejtm 4y agoalas this is true, I never correctly recall the order of particular function args as they are fairly random, still beats the alternative of having to continually internalize entire fragile ecosystems to achieve the same goal.
- boredtofears 4y agoyeah you're definitely right. im sure if it was something i had to use more consistently i'd be able to commit it to memory. maybe...
- chasil 4y agoBrian Kernighan covers the entire [new] awk language in 40 pages - chapter 2. There are people who have asked me scripting questions for over a decade, who will not read this for some reason. It could be read in an hour, but not fully retained. https://archive.org/download/pdfy-MgN0H1joIoDVoIC7/ https://archive.org/download/pdfy-MgN0H1joIoDVoIC7/