#37 bashrc: Clean up unused references to VTE
Merged 2 years ago by mosvald. Opened 2 years ago by rishi.

file modified
+1 -1
@@ -16,7 +16,7 @@ 

    if [ "$PS1" ]; then

      if [ -z "$PROMPT_COMMAND" ]; then

        case $TERM in

-       xterm*|vte*)

+       xterm*)

          if [ -e /etc/sysconfig/bash-prompt-xterm ]; then

              PROMPT_COMMAND=/etc/sysconfig/bash-prompt-xterm

          else

VTE has never ever set the TERM environment variable to vte*. For the
last 7.5 years, it has been setting TERM to xterm-256color [1].
Earlier it used to be xterm.

Things like gnome and vte are the inventions of the terminfo
maintainer, who also maintains xterm, and thinks that no other
terminal emulator should set TERM to xterm*. However, this doesn't
match reality.

Regardless, VTE owns its PROMPT_COMMAND through its own Bash
configuration snippet in /etc/profile.d/vte.sh which has (and must
have) a higher priority than /etc/bashrc [2]. Therefore, this cleans
up unused cruft and makes things a little less confusing.

[1] VTE commit 82a8b0697dd948fa
https://gitlab.gnome.org/GNOME/vte/-/commit/82a8b0697dd948fa
https://bugzilla.gnome.org/show_bug.cgi?id=740641

[2] Commit 718cfa4
https://pagure.io/setup/pull-request/23

rebased onto 4179a929d5fecfd511b64f1434be002031475a54

2 years ago

rebased onto 07f8deb

2 years ago

Thank you for the background info and the patch!

Pull-Request has been merged by mosvald

2 years ago
Metadata
Changes Summary 1