You are not logged in.
I wonder if someone can help me figure this out. I've started recently using emacs in daemon mode, and calling emacsclient from inside tmux. The problem is that there's a short delay (around 2 seconds) when I do this, before the file is opened.
Specifically, from within a tmux client, calling "emacsclient -t filename" loads the emacs frame instantly inside the terminal emulator, displaying the scratch buffer. I then have to wait a second or two before it loads the file. This is annoying.
Changing any of these variables seems to fix it: No tmux means that it works instantly. Also "emacsclient -c filename" opens a new window displaying the file instantly. It's a specific combination of starting the terminal version of emacs from within tmux that's triggering the delay. Also, any subsequent C-x C-f open that file instantly. It's just the first time.
What gives?
Last edited by petelewis (2011-06-10 08:13:10)
"Cared thou not, thou would have abstained." - Xyne
Offline
Responding to my own post for completeness :-)
Thanks to Josef Wells and the folk on #tmux, for this solution:
My TERM was set to xterm-256color inside tmux.
I changed that to screen-256color, and it immediately fixed the problem.
Now I set my TERM in my .bashrc to xterm-256color unless $TMUX is set,
in which case, screen-256color.
I've actually discovered that you can do this in ~/.tmux instead:
set-option -g default-terminal "screen-256color"
which avoids the need to put it in .bashrc (or equivalent), which would set the TERM variable even when not in tmux.
"Cared thou not, thou would have abstained." - Xyne
Offline