-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
dtach eats output of prev. commands #6
Comments
Dtach doesn't really understand the terminal emulator that you're using. It doesn't filter the output from the host at all. Because of this the 'alternate screen' that 'screen' and 'tmux' can use to preserve the previous state of the terminal is not available; it may be used by the program that you run using dtach. Now IF your problem is that you're running a text editor under dtach and the text editor would normally use the alternate screen but the screen is getting cleared with dtach. I may have a solution for you. The second item in my PR #5 will let you disable this clear screen. |
@safinaskar Could the behavior you're observing be because dtach tries to send Ctrl-L after reconnecting? I believe Ctrl-L "clears" the previous commands on the shell. Try and see if adding |
@ackerleytng , I tried |
(I just did this |
To start a session and record output: dtach -c /tmp/my-session.dtach script --flush /tmp/my-session.typescript To restore the output and attach to the session: sleep 0.1 && cat /tmp/my-session.typescript & dtach -a /tmp/my-session.dtach -r none The |
Type some commands to terminal. Then start dtach. Then exit from dtach. You will see all previous activity (i. e. before starting dtach) is disappeared (as opposed to screen and tmux).
$ dtach --version
dtach - version 0.9, compiled on May 21 2016 at 08:04:42.
The text was updated successfully, but these errors were encountered: