Bash PS1: Correctly enclose nonprintable sections
commit759a59f67bfcb7cf1fb11f289d04398eb78de908
authorBenoit Mortgat <mortgat@gmail.com>
Mon, 18 Jun 2012 12:19:12 +0000 (18 14:19 +0200)
committerBenoit Mortgat <mortgat@gmail.com>
Mon, 16 Jul 2012 10:51:51 +0000 (16 12:51 +0200)
treef1620db22181db414e7d265e2af5efc4de12ae5a
parent4e4e3f3fefab0ead3aa0b4822675355d40303b10
Bash PS1: Correctly enclose nonprintable sections

`\[` and `\]` are used for enclosing nonprinting characters in bash PS1.
Enclosing printable characters inside those bracket pairs results in bad
behaviour when the PWD contains characters from an extended character
set (not strictly in ASCII).

Therefore, instead of enclosing big chunks of PS1 inside `\[`...`\]`
pairs, we only put them around the small, non-printable character parts.

Signed-off-by: Benoit Mortgat <mortgat@gmail.com>
etc/profile