I have a program that can output its results only to files, with -o
option. This time I need to output it to console, i.e. stdout
. Here is my first try:
myprog -o /dev/stdout input_file
But it says:
/dev/ not writable
I've found this question that's similar to mine, but /dev/stdout
is obviously not going to work without some additional magic.
Q: How to redirect output from file to stdout
?
P.S. Conventional methods without any specialized software are preferable.
Many tools interpret a
-
as stdin/stdout depending on the context of its usage. Though, this is not part of the shell and therefore depends on the program used.In your case the following could solve your problem: