I wrote an ebook on GNU awk with hundreds of examples and exercises
-
I'm not expert in sed or awk. I always have to Google. For me though, it's generally that you can do a great deal in just one line of awk or sed. They're standard on any Linux distribution I've ever used. When building out pipelines, scripts that you want run from an installer you built post install and when removing, sed and awk rather than needing python.
All really nice when you have strict configuration management and versioning and there's something deployed but it doesn't have the python packages installed that would make it easy in python and you can't just pip install it on hundreds+ of computers without going through a process of approval and building a new tagged version release but sed/awk/etc can do the job. If it's hard enough, python and whatever packages you can install. If simple enough to do in a small bash script, no python just what's standard in your Linux distro
I'm not expert in sed or awk. I always have to Google. For me though, it's generally that you can do a great deal in just one line of awk or sed.
Same here ! I recently used a one liner awk piped into sed, piped into another command to find duplicated lines and merge both files.
Writing a python script would have taken an unknown amount of time !
-
Hello!
I am pleased to announce a new version of my CLI text processing with GNU awk ebook. This book will dive deep into field processing, show examples for filtering features, multiple file processing, how to construct solutions that depend on multiple records, how to compare records and fields between two or more files, how to identify duplicates while maintaining input order and so on. Regular expressions will also be discussed in detail.
Book links
To celebrate the new release, you can download the PDF/EPUB versions for free till 06-April-2025.
Or, you can read it online at https://learnbyexample.github.io/learn_gnuawk/
Interactive TUI apps
- 80+ exercises: https://github.com/learnbyexample/TUI-apps/blob/main/AwkExercises
- Brief tutorial: https://github.com/learnbyexample/TUI-apps/blob/main/AwkTutorial
Feedback
I would highly appreciate it if you'd let me know how you felt about this book. It could be anything from a simple thank you, pointing out a typo, mistakes in code snippets, which aspects of the book worked for you (or didn't!) and so on.
Happy learning
Perfect. I'm feeling comfortable enough with bash that next on my list is AWK. Gonna download this when I get home!
-
Hello!
I am pleased to announce a new version of my CLI text processing with GNU awk ebook. This book will dive deep into field processing, show examples for filtering features, multiple file processing, how to construct solutions that depend on multiple records, how to compare records and fields between two or more files, how to identify duplicates while maintaining input order and so on. Regular expressions will also be discussed in detail.
Book links
To celebrate the new release, you can download the PDF/EPUB versions for free till 06-April-2025.
Or, you can read it online at https://learnbyexample.github.io/learn_gnuawk/
Interactive TUI apps
- 80+ exercises: https://github.com/learnbyexample/TUI-apps/blob/main/AwkExercises
- Brief tutorial: https://github.com/learnbyexample/TUI-apps/blob/main/AwkTutorial
Feedback
I would highly appreciate it if you'd let me know how you felt about this book. It could be anything from a simple thank you, pointing out a typo, mistakes in code snippets, which aspects of the book worked for you (or didn't!) and so on.
Happy learning
-
Hello!
I am pleased to announce a new version of my CLI text processing with GNU awk ebook. This book will dive deep into field processing, show examples for filtering features, multiple file processing, how to construct solutions that depend on multiple records, how to compare records and fields between two or more files, how to identify duplicates while maintaining input order and so on. Regular expressions will also be discussed in detail.
Book links
To celebrate the new release, you can download the PDF/EPUB versions for free till 06-April-2025.
Or, you can read it online at https://learnbyexample.github.io/learn_gnuawk/
Interactive TUI apps
- 80+ exercises: https://github.com/learnbyexample/TUI-apps/blob/main/AwkExercises
- Brief tutorial: https://github.com/learnbyexample/TUI-apps/blob/main/AwkTutorial
Feedback
I would highly appreciate it if you'd let me know how you felt about this book. It could be anything from a simple thank you, pointing out a typo, mistakes in code snippets, which aspects of the book worked for you (or didn't!) and so on.
Happy learning
Thanks but omg no. I'm happy to use awk like cut.
-
i'm in awe everytime people do this.
i learned how to do this before code sharing sites like github existed and it forced me to turn everything i've learned into muscle memory and i think that this next generation of greybeards are going to be so much better than my generation's greybeards because of it.
I thought your comment was going in a totally different direction, it's nice to hear appreciation of improved teaching methods instead of the old "well I figured it out myself so everyone else should too"
-
Hello!
I am pleased to announce a new version of my CLI text processing with GNU awk ebook. This book will dive deep into field processing, show examples for filtering features, multiple file processing, how to construct solutions that depend on multiple records, how to compare records and fields between two or more files, how to identify duplicates while maintaining input order and so on. Regular expressions will also be discussed in detail.
Book links
To celebrate the new release, you can download the PDF/EPUB versions for free till 06-April-2025.
Or, you can read it online at https://learnbyexample.github.io/learn_gnuawk/
Interactive TUI apps
- 80+ exercises: https://github.com/learnbyexample/TUI-apps/blob/main/AwkExercises
- Brief tutorial: https://github.com/learnbyexample/TUI-apps/blob/main/AwkTutorial
Feedback
I would highly appreciate it if you'd let me know how you felt about this book. It could be anything from a simple thank you, pointing out a typo, mistakes in code snippets, which aspects of the book worked for you (or didn't!) and so on.
Happy learning
Btw, there's asciidoctor-epub3.
-
Perfect. I'm feeling comfortable enough with bash that next on my list is AWK. Gonna download this when I get home!
You misstyped fish.
-
You misstyped fish.
Heh. I haven't started exploring other shells yet.
-
Hello!
I am pleased to announce a new version of my CLI text processing with GNU awk ebook. This book will dive deep into field processing, show examples for filtering features, multiple file processing, how to construct solutions that depend on multiple records, how to compare records and fields between two or more files, how to identify duplicates while maintaining input order and so on. Regular expressions will also be discussed in detail.
Book links
To celebrate the new release, you can download the PDF/EPUB versions for free till 06-April-2025.
Or, you can read it online at https://learnbyexample.github.io/learn_gnuawk/
Interactive TUI apps
- 80+ exercises: https://github.com/learnbyexample/TUI-apps/blob/main/AwkExercises
- Brief tutorial: https://github.com/learnbyexample/TUI-apps/blob/main/AwkTutorial
Feedback
I would highly appreciate it if you'd let me know how you felt about this book. It could be anything from a simple thank you, pointing out a typo, mistakes in code snippets, which aspects of the book worked for you (or didn't!) and so on.
Happy learning
Could you do grep next?
-
Could you do grep next?
Already done grep, sed, coreutils, cli basics and more. See https://learnbyexample.github.io/learn_gnuawk/buy.html#book-list for links.
-