Don't let useless cat commands make you hiss-terical! Get a grip with grep on #Linux, #macOS, #FreeBSD & #Unix. It's purr-fect for the job! 😼 https://www.cyberciti.biz/faq/howto-use-grep-command-in-linux-unix/
Conversation
Notices
-
nixCraft 🐧 (nixcraft@mastodon.social)'s status on Thursday, 30-May-2024 20:03:38 JST nixCraft 🐧 -
Aiono (aiono@mastodon.social)'s status on Thursday, 30-May-2024 20:11:59 JST Aiono @nixCraft
Why waste time to learn how to read a file for every single command I use instead of just piping cat? I think using cat is more aligned with the Unix philosophy. -
lhp (lhp@mastodon.social)'s status on Thursday, 30-May-2024 20:44:04 JST lhp @nixCraft Complaining about cat abuse, but letting the cat live in the bin. Hmm... 🐈
Please let your cats inside, they are cold:
mv /bin/cat ~ -
Ben Lamb (bennyfactor@mastodon.social)'s status on Thursday, 30-May-2024 22:38:34 JST Ben Lamb @nixCraft echo "/path/filename" | xargs cat | grep "string"
-
loganer (loganer@mastodon.social)'s status on Friday, 31-May-2024 00:21:33 JST loganer @nixCraft no.
i will continue to use cat and grep like this because it just looks freaking weird as hell the other way around.the source should be on the left and the target should be on the right.
-
acb (acb@mastodon.social)'s status on Friday, 31-May-2024 00:37:41 JST acb @nixCraft The example with cat is less efficient (one extra process), but it is more composable (if you wanted to put something before the grep, you could)
-