0

I want to read the contents of the file into the buffer and stdout it to the screen. I did this:screen -X readbuf /home/nitro/file|screen -X writebuf|cat /tmp/screen-exchangebut cat command showed me screen-exchange file with the previous result of readbuf command. If I do this commands separately - everything will be correct and I'll get the modified screen-exchange file.

How can I perform all three commands readbuf, writebuf and cat at once?

fuser
  • 283
  • 2
  • 7
  • 18

1 Answers1

0

This works for me:

screen -X eval "readbuf /tmp/x" writebuf && cat /tmp/screen-exchange
ma-ti
  • 126
  • 8