Didek_@lemmy.ml to Linux@lemmy.ml · 3 years agoOutput file to stdin while removing it?message-squaremessage-square4fedilinkarrow-up13arrow-down11file-text
arrow-up12arrow-down1message-squareOutput file to stdin while removing it?Didek_@lemmy.ml to Linux@lemmy.ml · 3 years agomessage-square4fedilinkfile-text
Hey, does anybody know is there a way to remove a file while read? Something like: rm file.txt -o - | cat - ?
minus-squarespace_cowboy@lemmy.mllinkfedilinkarrow-up2·3 years agowhy not just read the file, then remove it: cat file.txt && rm file.txt Not that I understand why you would want to do this anyway; it kind of doesn’t make any sense.
minus-squareDidek_@lemmy.mlOPlinkfedilinkarrow-up1·3 years agoJust courious, it’s not something that will be useful, thanks.
why not just read the file, then remove it:
Not that I understand why you would want to do this anyway; it kind of doesn’t make any sense.
Just courious, it’s not something that will be useful, thanks.