Fw: failure notice

Thomas Wolff towo@towo.net
Mon Aug 27 10:42:00 GMT 2018


> ...
>
>        PS1="\[\e[1;32m\]\h \! $ \[\e[0m\] "
>
> The real issues is that I still have no real clue on how these escape
> sequences work!! ...
`man bash`, section PROMPTING; the \[ and \] are not escape sequences 
for the terminal but meta syntax in the prompt, telling the shell that 
the string inside is an escape sequence and shall not be accounted for 
prompt line width. If you get that wrong, the shell will obviously be 
confused about its respective current position.

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple



More information about the Cygwin mailing list