After upgrading from Fedora Core 36 to 37 I noticed that tput sgr0 0
has started reporting errors for root
, but not for other users.
root$ tput -V
ncurses 6.2.20201017
root$ echo $TERM
xterm-256color
root$ tput sgr0 0
tput: unknown terminfo capability '0'
I realize that I must have added the last 0
in my script by mistake and that it should simply be tput sgr0
- but for some reason this output only shows up when running as root
and it didn't show up in FC36 so I got curious about it. It doesn't matter if I use bash or tcsh - same thing.
root
has the same TERM
as my normal users for whom this output doesn't show up. The characters printed prior to, and after, the sgr0 0
sequence is also the same for all users (including root
). It's a ~
before and a space after.
Can someone explain what's going on?