Behavior change in TERM after FreeBSD 14.1 update

After system update to FreeBSD 14.1 from 13.2 output of following commands
top, iftop, syscat
disappears as fast as you quit them. While previously their output was reamining on the screen.
This behavior is observable with following $TERM value:
$ echo $TERM
xterm-256color
When $TERM is changed to "vt100" on both version of system behavior is identical to that of FreeBSD 13.2 with TERM set to xterm-256 color.
The question is - is such change intentional?
 
I cannot reproduce that behavior using xterm, awesome and the modesetting driver on a Mesa Intel(R) HD Graphics 620 (KBL GT2). After quitting top the last output is still visible and the prompt is below.
 
I cannot reproduce that behavior using xterm, awesome and the modesetting driver on a Mesa Intel(R) HD Graphics 620 (KBL GT2). After quitting top the last output is still visible and the prompt is below.

It's not graphics card related. It's question related to recognition of terminal type.
 
My 14.1R also has the screen intact on xterm-256color.
If you want to restore the screen, there is xterm-clear.
/usr/share/misc/termcap
On the other hand, if you want to leave it as it is, you can use :te@: in termcap.

The termcap has not been changed.
share/termcap/termcap
 
It's not graphics card related. It's question related to recognition of terminal type.
Sorry, I forgot to mention the the terminal is as yours.
Code:
[I] chris@thinkpad ~> echo $TERM
xterm-256color
About termcap, I have not modified anything, too.
 
After system update to FreeBSD 14.1 from 13.2 output of following commands
top, iftop, syscat
disappears as fast as you quit them. While previously their output was reamining on the screen.
This behavior is observable with following $TERM value:
$ echo $TERM
xterm-256color
When $TERM is changed to "vt100" on both version of system behavior is identical to that of FreeBSD 13.2 with TERM set to xterm-256 color.
The question is - is such change intentional?
Sounds like the same extremely annoying behavior seen on linux/bash. On my linux terminals I have the following in $HOME/.vimrc:
set t_te= t_ti=

Are you by any chance using bash or something similar?
 
Key phrase:
  • alternate screen buffer.
… is such change intentional?

Yes. Maybe 14.0-RELEASE.

Code:
% rg --sort path ncurses /usr/doc/website/content/en/releases/14.0R
/usr/doc/website/content/en/releases/14.0R/relnotes.adoc
496:The `libncursesw` library (see man:ncurses[3X]) has been split into `libtinfow` and `libncursesw`.
498:man:pkg-config[8] files are now installed, to ease ports detecting the `ncurses` setup from base.
501:The man:ncurses[3X] library is now able to use man:terminfo[5] as well as man:termcap[5], and uses terminfo preferentially.
504:The default search path for terminfo databases in man:ncurses[3X] now includes [.filename]#/usr/local/share/terminfo#, facilitating the use of a database from ports or packages.
%

Base 61f66a1f4403fded9aae14d890ad96914a3c0bc1:

ncurses: Add support for terminfo database

Along with the termcap database, ncurses will now lookup for the terminfo database, note that the terminfo database is being looked up first and then it fallsback on the termcap one.

While here drop our custom reader for the termcap database, over the time it is needed maintenance to be able to catchup with changes on ncurses side.

Install the ncurses tools which are needed to deal with the terminfo database: tic, infocmp, toe

Replace our termcap only aware tools with the ncurses counterpart: tput, tabs, tset, clear and reset

In particular they can your the extra capabilities described in the terminfo database, which does not exist in termcap

Note that to add a new terminfo information to the database from ports the ports will just need to add their extra information into: /usr/local/share/site-terminfo/<firstletteroftheterm>/<term>

Tested by: jbeich, manu



Code:
% rg --sort path 'alternate screen buffer' /usr/src
/usr/src/contrib/ncurses/misc/terminfo.src
5726:xterm1|xterm terminal emulator ignoring the alternate screen buffer,
%

Historically, xterm-clear was a commonplace workaround to not getting the alternate screen buffer with xterm-256.
 
I say maybe, because elsewhere I wrote:

… fresh installations of 14.0-RELEASE, the default TERM=xterm-256color does not do what I want. …

I do want the alternate screen buffer.

Postscript: maybe misc/terminfo-db is what's required (I do have that on my everyday notebook with 15.0-CURRENT).
 
The terminal's behavior is affected by /usr/local/share/terminfo/x/xterm-256color from misc/terminfo-db. Deleting this file fixes the terminal and makes TERM=xterm-256color work properly again.
 
Back
Top