cm0002@lemmy.world to Programmer Humor@programming.dev · 4 months agoLinux Userslemmy.mlimagemessage-square135fedilinkarrow-up11.24Karrow-down125cross-posted to: programmerhumor@lemmy.ml
arrow-up11.21Karrow-down1imageLinux Userslemmy.mlcm0002@lemmy.world to Programmer Humor@programming.dev · 4 months agomessage-square135fedilinkcross-posted to: programmerhumor@lemmy.ml
minus-squareHammerheart@programming.devlinkfedilinkarrow-up2·4 months agoYes, it was meant to be a self deprecating admission that I have used this unnecessarily verbose command.
minus-squareechindod@programming.devlinkfedilinkarrow-up2·4 months agoAh. Well. I can not be blameless on this. I also probably use cat unnecessarily still. But less so with grep these days. I’m getting better… I swear!
minus-squaredisobey2623@lemmy.dbzer0.comlinkfedilinkarrow-up2·4 months agoYou saying I can just skip cat in that command and it works?
minus-squaredisobey2623@lemmy.dbzer0.comlinkfedilinkarrow-up4·4 months agoHow did I not know this. Thank you!
minus-squareoozynozh@sh.itjust.workslinkfedilinkarrow-up2·4 months agoit’s grep STRING FILE to be precise or awk '/STRING/′ FILE if you prefer that for some reason
minus-squareulterno@programming.devlinkfedilinkEnglisharrow-up0·4 months agoMy output was empty for that command. Guess why? Because history only gives the last few lines in my system.
Useless use of cat?
Yes, it was meant to be a self deprecating admission that I have used this unnecessarily verbose command.
Ah. Well. I can not be blameless on this. I also probably use cat unnecessarily still. But less so with grep these days. I’m getting better… I swear!
You saying I can just skip cat in that command and it works?
How did I not know this. Thank you!
it’s
grep STRING FILEto be preciseor
awk '/STRING/′ FILEif you prefer that for some reasonhistory | grep 'cat'My output was empty for that command.
Guess why?
Because
historyonly gives the last few lines in my system.