summaryrefslogtreecommitdiffstats
path: root/git-radar
diff options
context:
space:
mode:
authorMichael Allen <michael@michaelallen.io>2015-08-26 13:39:39 +0100
committerMichael Allen <michael@michaelallen.io>2015-08-26 13:39:39 +0100
commit11e8ad4bdce9979eb871635bf455213788de5e05 (patch)
tree5907059a7ea660a1cc6644c943338ae10ee2c3c7 /git-radar
parent1faeef884d3660ca4048892fef0ef78997aad821 (diff)
downloadgit-sonar-11e8ad4bdce9979eb871635bf455213788de5e05.tar.gz
git-sonar-11e8ad4bdce9979eb871635bf455213788de5e05.zip
Bypass PS1s conversion of \[
In PS1 you need to escape non-printing characters, like the color codes. The standard way is wrapping it in `\[` and `\]`. But for a dynamic prompt, i.e. one that renders the results of a function every time the prompt renders, that `\[` will be output as literals. To fix this we bypass the conversion and wrap our non-printing characters in the desired characters directly: `\[` -> `\x01` `\]` -> `\x02`
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions