Соляризация в Konsole + tmux + vim

1480
toliveira

Соляризованная цветовая схема прекрасно работает при использовании Konsole + vim, но я не могу понять, как правильно настроить мой компьютер для использования Konsole + tmux + vim (см. Скриншоты по ссылкам).

Ниже приведена конфигурация, которую я использую.

На Konsole:

user:~$ echo $TERM xterm-256color user:~$ cat .tmux.conf | grep terminal set -g default-terminal "xterm-256color" #"screen-256color" gives the same result user:~$ cat .vimrc :filetype plugin on  syntax enable set term=xterm-256color let g:solarized_termcolors=256 set t_Co=256 set background=dark colorscheme solarized 

В tmux:

user:~$ echo $TERM xterm-256color 

Не могли бы вы предложить, пожалуйста?

0
Возможно, вам следует установить для `term` значение` screen-256color` вместо `xterm-256color`. [http://superuser.com/a/399326/431697] Также попробуйте вызвать tmux с опцией `-2`. Philipp Moers 8 лет назад 0

2 ответа на вопрос

1
toliveira

According to http://blog.sanctum.geek.nz/term-strings/:

" A certain piece of very misleading advice is often given online to users having problems with the way certain command-line applications are displaying in their terminals. [...] This misinformation sometimes extends to suggesting that users put the forced TERM change into their shell startup scripts. The reason this is such a bad idea is that it forces your shell to assume what your terminal is, and thereby disregards the initial terminal identity string sent by the emulator."

Following their suggestion, I have erased from ~/.bashrc, ~/.vimrc and ~/.tmux.conf every mention to the terminal.

Now I have at Konsole:

user:~$ echo $TERM xterm 

at tmux:

user:~$ echo $TERM xterm-256color 

and everything works well.

-1
kujaw

Я искал много решений и нашел цветовую схему Flattered, которая в основном соляризована, но настроена настолько хорошо, что она работает из коробки в tmux на моей машине. Ссылка:
https://github.com/romainl/flatened