Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

This problem is related to the thread.

The line in my .zshrc

export LESS_TERMCAP_mb=$'\E[01;31m'     # begin blinking

The following seems to mean

  • \$ starts the expression
  • ' -- ' says everything in the brackets matters
  • \E apparently says that apply the following command
  • [01 seems to refer to the beginning of a file
  • ; seems to indicate between the beginning of the previous to
  • 31m which seems to be the end of a file

The statement is still confusing. Some pattern must match "a begin" and "blinking".

How do you read the line?

share|improve this question
I need to solve this problem first to solve the other problem here:… – Masi Jul 2 '09 at 17:50
See also Documentation on LESS_TERMCAP_* variables? – Gilles Jan 11 '14 at 4:12
up vote 4 down vote accepted

This is an ANSI color sequence.

  • The $'...' means interpret backslash-escaped characters (like \e or \n) (see the "Quoting" section of the bash man page)
  • \E is the escape character (ASCII 27 decimal)
  • [ is just a square bracket
  • so Esc-[ begins the color sequence
  • 01 is "bright"
  • ; delimits colors
  • 31 is "red"
  • m is the end of the color sequence

The sequence Esc-[ 0 m resets to default colors.


 echo $'\E[01;31m'Hello$'\E[0m' Masi

See this Wikipedia article for more information.

share|improve this answer
Thank you for your answer! – Masi Jul 2 '09 at 21:38

Your Answer


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.