In ZSH prompt expansion, the command %E is supposed to "Clear to end of line."

This works: enter image description here

However, it does not work in tmux: enter image description here

The issue seems to be with BCE (Background Color Erase). In screen, I can add the option defbce on. I can't find any similar setting for tmux. Does it exist?

  • ensure you are not overriding TERM=screen to something else. – meuh Dec 28 '15 at 8:46
  • Without tmux TERM is xterm-256. With tmux, TERM is screen. – JoshuaD Dec 28 '15 at 19:04
up vote 4 down vote accepted

Unlike screen, tmux does not have switchable background colour erase capability in its terminal emulator. Erasure is always with the default background colour, never the current background colour.

Nicholas Marriott added it to the to-do list in September 2015, but stated that neither he nor anyone else cares enough about it to implement it.

Further reading

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

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