Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move away from termbox, tmux compatibility #263

Open
jinnatar opened this issue May 27, 2021 · 2 comments
Open

Move away from termbox, tmux compatibility #263

jinnatar opened this issue May 27, 2021 · 2 comments

Comments

@jinnatar
Copy link

On latest 0.7.5:

%> ./ctop-0.7.5-linux-amd64 
panic: termbox: error while reading terminfo data: termbox: unsupported terminal [recovered]
        panic: termbox: error while reading terminfo data: termbox: unsupported terminal

goroutine 1 [running]:
main.panicExit()
        /home/bradley/work/bcicen/ctop/main.go:147 +0x6b
panic(0xaf0de0, 0xc0001c0e70)
        /usr/lib/go/src/runtime/panic.go:969 +0x1b9
main.main()
        /home/bradley/work/bcicen/ctop/main.go:104 +0x9a7
%> echo $TERM 
tmux-256color

The issue seems to stem from nsf/termbox-go/issues/215 which is already several years old and is not getting fixed.
The project in fact is in maintenance mode:
"This library is somewhat not maintained anymore. " ... " If you're looking for a Go lib that provides terminal-based user interface facilities, I've heard that gdamore/tcell is good ..."

Ergo, to fix this issue the solution is probably to move away from termbox, perhaps to tcell.

A workaround in the meanwhile is to lie in .tmux.conf and use screen termcap, but this causes other issues:

set -g default-terminal screen-256color
@xbb
Copy link

xbb commented Jun 11, 2021

Another workaround is to use an alias like:

alias ctop='TERM="${TERM/#tmux/screen}" ctop'

@mbirth
Copy link

mbirth commented Mar 19, 2024

Or in fish:

alias ctop='TERM="(string-replace tmux screen $TERM)" /usr/bin/ctop'

Make it permanent with funcsave ctop afterwards.

l-lin added a commit to l-lin/dotfiles that referenced this issue Aug 10, 2024
No longer maintained, and I have some issue displaying in Kitty+Tmux.
See bcicen/ctop#263.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants