Top products from r/bash

We found 10 product mentions on r/bash. We ranked the 6 resulting products by number of redditors who mentioned them. Here are the top 20.

Next page

Top comments that mention products on r/bash:

u/brakkum · 1 pointr/bash

I really love this book, has tons of great info in it. Might be able to find it online somewhere.

https://www.amazon.com/Linux-Command-Shell-Scripting-Bible/dp/111898384X/ref=pd_lpo_sbs_14_t_0?_encoding=UTF8&psc=1&refRID=KDKCH1GWS30M5R9G2Z3A

Otherwise, come up with a simple task you want to accomplish, and try and break it down into small steps. Then do some reading on basic bash commands and try and piece it together from there!

u/colemaker360 · 1 pointr/bash

If you're open to learning a little awk, it can handle this in a breeze with a one-liner:

awk '/^\s*$/{next}{arr[$1]++}END{for (a in arr) print a, arr[a]}' test.log

Breaking it down:

  • awk assumes space is the field delimiter. You can pass a different delimiter if you want.
  • /^\\s*$/{next} means if the line is empty, ignore it
  • {arr[$1]++} means make an array that holds your counts. `$1` means the first field
  • If you have a header line that you don't want to count, change it to NR>1{arr[$1]++}
  • END{for (a in arr) print a, arr[a]} means at the end of processing, loop through the array you made and print the results

    awk is super powerful, and a lost art. This book is a great read if you can pick up a used one.
u/drpinkcream · 3 pointsr/bash

I recommend How Linux Works and The Linux Command Line. Those will take a total beginner and take you through the basics up to shell scripting.

The Linux Command Line is a work book where you type what it says and follow along. How Linux Works is more of an explanation with less hands-on. I went through both at the same time as the chapters align very well, particularly at the beginning.

u/agopo · 1 pointr/bash

Thanks for the advice! I'm still new to bash scripting and can make use of that. The "put your then's and do's on the same line as your for's and if's and while's" for example makes a lot of sense, coming to think about it.

Also, in #bash they told me the same thing about variables: Only systemwide variables like EDITOR or PATH should be uppercase, else lowercase. Guess Jason Cannon's "Shell Scripting" was wrong about that. ;)

Keeping my own index file is what I plan to do next. Again, the #bash elders advised something similiar: To keep all mp3s filenames in an array. That might hog some memory but it supposedly faster than searching the whole filesystem.