Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

When starting tmux I need to pass a valid terminal type. Since I am scripting the initial startup of tmux I would like to cover all bases by figuring out the valid values of TERM on the current system.

How do I find valid values to use for tmux and which order, including a possible 16 color fallback, should I prefer?

This is mainly for Linux systems, but I presume the approach would be similar on most other unixoids.

share|improve this question
    
Why isn't your terminal setting one already? –  Ignacio Vazquez-Abrams Jan 25 '13 at 18:52
    
It is, but that's not compatible with the way I want/need to run tmux. In order to force it to use 256 colors, I need to explicitly set it on the server I am connecting to. –  0xC0000022L Jan 25 '13 at 18:57
add comment

1 Answer

up vote 6 down vote accepted

The toe command will show you the terminfo definitions on the current system. If you lack that command, you see the raw data in /usr/share/terminfo on most Linux systems.

share|improve this answer
    
Great, thanks. toe -a|awk '{print $1}' is the kind of list I have been looking for. +1 and accept :) –  0xC0000022L Jan 25 '13 at 18:59
    
Nice! Didn't know of toe until now. –  Herman Torjussen Jan 25 '13 at 22:14
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.