How to view a text file on your Linux or Unix box like a pro
Conversation
Notices
-
Embed this notice
nixCraft 🐧 (nixcraft@mastodon.social)'s status on Saturday, 12-Aug-2023 06:05:10 JST nixCraft 🐧 -
Embed this notice
Haelwenn /элвэн/ :triskell: (lanodan@queer.hacktivis.me)'s status on Saturday, 12-Aug-2023 06:05:09 JST Haelwenn /элвэн/ :triskell: @nixCraft cp /etc/passwd /dev/stdout
-
Embed this notice
Haelwenn /элвэн/ :triskell: (lanodan@queer.hacktivis.me)'s status on Saturday, 12-Aug-2023 07:09:00 JST Haelwenn /элвэн/ :triskell: @locness3 @nixCraft You’d need a function, cat needs to handle multiple files, cp with 2+ origins wants the destination to be a directory.
Also it makes coreutils says rather funny things if you want the behavior of argument-less cat:
$ cp /dev/stdin /dev/stdout cp: '/dev/stdin' and '/dev/stdout' are the same file -
Embed this notice
Eugène aka locness3 (locness3@miruku.cafe)'s status on Saturday, 12-Aug-2023 07:09:05 JST Eugène aka locness3 @lanodan@queer.hacktivis.me @nixCraft@mastodon.social any reason not to make cat an alias of that?
-
Embed this notice