Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

My daily bash pattern.

  cat file
  cat file | grep something



You could just `grep "something" file.


Indeed - it's a known anti-pattern[0].

[0] https://en.wikipedia.org/wiki/Cat_(Unix)#Useless_use_of_cat


I prefer less tbh, less pollution of the term output.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: