1

I have this problem while working on a screen session that the terminal line gets overwritten. If I detach from the screen session then I don't run into this problem.

Here are some of the configurations that I believe might help:

[~]$cat ~/.screenrc
altscreen on
defscrollback 15000
termcapinfo xterm* ti@:te@
termcapinfo *  vb=:
vbell off

[~]$screen --version
Screen version 4.01.00devel (GNU) 2-May-06

[~]$echo $SHELL
/bin/bash

[~]$echo $COLUMNS
234

[~]$echo $TERM
screen

[~]$echo $PS1
\[\e[1;32m\][\w]\$\[\e[0m\]

I have shopt -s checkwinsize in my .bashrc. I've gone through this but I already have most of what is suggested (enclosing colored PS1 in [ and ] and having COLUMNS set to a reasonably large value). Is there anything else that I need to set as part of my environment to fix this? The one obvious difference I see is that TERM is set to xterm when I detach from a screen session.

Illustrations that I hope might help explain my problem:

Initial:

Before overwrite

After overwrite:

After overwrite

On detaching from screen:

On detaching from screen

Zoso
  • 111
  • Could you describe the problem you're facing? – egmont Aug 29 '19 at 07:05
  • 1
    @egmont "I have this problem while working on a screen session that the terminal line gets overwritten. If I detach from the screen session then I don't run into this problem." This is the problem. Please do tell if the issue isn't still clear. – Zoso Aug 29 '19 at 07:58
  • Well, repeating the same words isn't quite what I expected. "The terminal line gets overwritten" – what do you mean by this? Do you mean the "terminal line" as /dev/pts/0 or something similar, analogous to let's say a phone line? Or by "terminal line" do you mean a physical row of the display containing unexpected things? Or do you mean the value of $TERM, is that the problem? Or what else? What do you exactly do inside screen, what commands do you issue, what is the exact output that you have a problem with, what output would you expect to see instead? (Please edit the post to answer these) – egmont Aug 31 '19 at 20:46
  • On a side note, I can't help notice that you're using an ancient version of screen, all currently supported Ubuntu releases ship a newer one. – egmont Aug 31 '19 at 20:48
  • @egmont I've added illustrations to explain my problem. And by terminal line, I'm referring to the bash terminal (/dev/pts/4) – Zoso Sep 02 '19 at 16:03

0 Answers0