In the command line, I typed:
script -a myfile
Then, I typed the some standard commands.
When I opened the myfile
using vi
, the file was empty. Why is that?
And, also, any tips on using the ttyrec
and ttyplay
commands?
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It only takes a minute to sign up.
Sign up to join this communityIn the command line, I typed:
script -a myfile
Then, I typed the some standard commands.
When I opened the myfile
using vi
, the file was empty. Why is that?
And, also, any tips on using the ttyrec
and ttyplay
commands?
It doesn't look like your implementation of script is flushing the output by default. If it available, try this:
script -f -a myfile
That said, I would suggest that you use more or less commands to view the file. In fact, you probably want to view that file in a separate login session, as your vi/more/less session will be flushed to the file in realtime.