Set Konsole's TERM variable to xterm-256color by default
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
KDE Base |
Won't Fix
|
Undecided
|
|||
konsole (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
It would be great to have applications like vim use nice color schemes (i.e. 256 colors) by default in Konsole. To make this happen, Konsole needs to indicate its 256 color support via the TERM variable.
One way to do this might be to patch /usr/share/
--- current/
+++ 256colors/
@@ -1,4 +1,5 @@
[General]
+Environment=
Name=Shell
Name[af]=Tolk
Name[ar]=الصدفة
Users' existing Konsole profiles would have to be adjusted manually.
For comparison, "echo $TERM" in several distributions' (current live systems) main terminal emulators prints:
xterm-256color in:
Ubuntu Xenial (recent daily) - GNOME Terminal
Fedora 23 (Workstation Edition) - GNOME Terminal
Fedora 23 (KDE) - Konsole (but xterm in Konsole profile, see Fedora Wiki URL below)
xterm in:
Xubuntu Xenial (recent daily) - xfce4-terminal
Tanglu 3 KDE - Konsole
Tanglu 3 GNOME - GNOME Terminal
This KDE bug report from 2011 AFAICT indicates it's up to the user/distribution to make sure 256 colors are supported (see below) and then set TERM (in Konsole) accordingly: https:/
256 color support via TERM=xterm-256color AFAICT needs /lib/terminfo/
For more discussion on different methods to set TERM (2012/2013): https:/
As a side note, using xterm-256color also had the nice side effect of enabling a colored Bash prompt in Konsole/Kparts by default (see default .bashrc).
tags: | added: kubuntu |
tags: | added: xenial |
Changed in kde-baseapps: | |
importance: | Unknown → Undecided |
status: | Unknown → Won't Fix |
This is for https:/ /fedoraproject. org/wiki/ Features/ 256_Color_ Terminals
There is a central script for that feature that is used to enable 256 colors
by adjusting the TERM variable.
However to do that safely it must know the terminal can support this.
The preferred method is to check the $COLORTERM env variable
that many terminals set.
I suggest setting it COLORTERM to 'konsole'
I tested setting that variable manually, from the preferences menu, share/apps/ konsole/ Shell.profile file COLORTERM= konsole, TERM=xterm
where there is an option to add environment variables.
All worked as expected. Note when setting manually (per user) the file:
~/.kde/
is updated with:
Environment=
thanks,
Pádraig.