Sign up ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm new to Emacs, and I'm trying to switch my workflow to using my terminal through Emacs.

I'm a Zsh user, and I love my terminal. I've been fiddling around with ansi term for a while now, and got my encoding sorted out.

But there's one issue that remains, and can be seen in the screenshots below:

This is what my terminal looks like in iTerm2 (with oh-my-zsh):

enter image description here

And this is what it looks like in ansi term (iTerm2, Emacs):

enter image description here

I'm curious what creates these strange line breaks and %-characters.

Anybody have a clue?

share|improve this question
Just a note, as you logged off #emacs: having TERM set to xterm, is probably part of the problem, as Emacs ansi-term isn't xterm, and if zsh thinks it is, it will do things that ansi-term probably doesn't understand. The default TERM setting for ansi-xterm seems to be "eterm-color", so I'd try setting TERM to that ("TERM=eterm-color" in the shell), and see whether zsh is better behaved. – snogglethorpe Aug 17 '13 at 23:44
If I strictly define TERM to be eterm-color. The issues remain the same, and I get coloring issues (ie. '4m' pops up before my prompt). Currently I use this '[[ $TERM == eterm-color ]] && export TERM=xterm' in my .zshrc, which the coloring issue. – Thomas Kobber Panum Aug 18 '13 at 7:59

Your Answer


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

Browse other questions tagged or ask your own question.