What 016 017 in bash prompt, how can I make it correct in Terminal

I saw a beautiful bash prompt here

PS1="\n\[\e[30;1m\]\[\016\]l\[\017\](\[\e[34;1m\]\u@\h\[\e[30;1m\])-(\[\e[34;1m\]\j\[\e[30;1m\])-(\[\e[34;1m\]\@ \d\[\e[30;1m\])->\[\e[30;1m\]\n\[\016\]m\[\017\]-(\[\[\e[32;1m\]\w\[\e[30;1m\])-(\[\e[32;1m\]\$(/bin/ls -1 | /usr/bin/wc -l | /bin/sed 's: ::g') files, \$(/bin/ls -lah | /bin/grep -m 1 total | /bin/sed 's/total //')b\[\e[30;1m\])--> \[\e[0m\]"

It should looks like:

Example

After I added in my .bashrc, I found \[\016\]l\[\017\] and \[\016\]m\[\017\] doesn't correct in my terminal (for both gnome-terminal and konsole): My prompt1

I found it works fine by pressing ctrl+alt+f1.

How can I make \[\016\]l\[\017\] and \[\016\]m\[\017\] works in my x-terminal?


My Investigation and environment:

  • 016/017 in ASCII are: SO (shift out) and SI (shift in)
  • My environment: Ubuntu 14.04

The Bashish theme howto says Shift Out "invokes the G1 (alternate) character set". I'm not sure, but it seems like your terminal either does not support that or the font you're using has no alternate character set.

About the 'alternate linedrawing character set' has a lot more details about this seemingly rather complex issue.