cat has two different behaviours depending on if its input is a string of file. I need to use cat to pipe a file to my PDF viewer (Zathura). The file name is based on a modified string with sed as follow:
cat <(echo test.tex | sed 's/[^.]*$/pdf/') | zathura -
I want this one liner to convert a file name string test.tex to test.pdf and pipe it to Zathura to open the corresponding file. The above command line is not working because the cat input is interpreted as a string and not as a file.
Obviously,
echo test.tex | sed 's/[^.]*$/pdf/') | zathura
is not working, that's why I try to mess around with cat.