byobu not displaying dircolors properly

Bug #817690 reported by Aaron Lake on 2011-07-28
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Dustin Kirkland 

Bug Description

Using Byobu version 3.33-0ubuntu1.1 on Ubuntu Natty I'm having a problem with dircolors being displayed correctly. I'm using the popular Solarized color theme with Putty on Windows and iTerm2 on OS X. Initially I thought there was a configuration problem on my end, however, a bit more digging leads me to believe that byobu handles bold colors differently then a vanilla shell. After I modified my color scheme to set bold colors to be identical to regular colors (Blue Bold == Blue, etc.) the dircolors are now displaying properly.

I believe this is a byobu bug, and not a bug with the Solarized color scheme since the dircolors display properly outside byobu. Using a 256 color terminal my prompt displays properly too.

Commands ran in within byobu:
alake@foxery:~/askubuntu » dircolors -p > ~/.dircolors
alake@foxery:~/askubuntu » echo $TERM >> ~/.dircolors

### Restarted ssh session here

alake@foxery:~/askubuntu » alias ls
ls='ls --color=tty'
alake@foxery:~/askubuntu » echo $TERM && grep $TERM ~/.dircolors
TERM screen-256color-bce
alake@foxery:~/askubuntu » dpkg -la | grep -i byobu
ii byobu 3.33-0ubuntu1.1 a set of useful profiles and a profile-switcher for GNU screen

See the screenshot for a further explanation.

This bug might be related to:

Aaron Lake (aaron-lake) wrote :
Dustin Kirkland  (kirkland) wrote :


I suspect that this bug is related to Bug #727466.

Could you try adding:
  attrcolor b ".I"
to your ~/.screenrc and restarting byobu?

And if that doesn't work, try adding:
  attrcolor b ".i"
to your ~/.screenrc and restarting byobu.

And let me know how it goes...

Changed in byobu:
importance: Undecided → Medium
status: New → Incomplete
Hannes Koller (hannes-koller) wrote :

Hi, I am having the same problem on my Kubuntu 11.04 install. I tried both settings Dustin suggested, but to no avail. Anything else I could attempt? Would be happy to get rid of this little annoyance. :)

Hmm, okay, then this must be more widespread than I was thinking.

Two requests:
 1) Can you post a screen shot, so that we can see if the errors look
more or less the same?
 2) Could you try downgrading to some of the Byobu releases at If you find any that work, it would help me
bisect the regression, as I suspect that this hasn't always been a
problem (it's only really coming up a lot recently)


Hannes Koller (hannes-koller) wrote :

I have attached a screenshot that shows the difference. This was taken with byobu Version: 3.33-0ubuntu1 . Following your suggestion I tried to manually install different versions of byobu. Installing Version: 3.5-0ubuntu1 fixed the problem for me.
Thanks for your support!

Dustin Kirkland  (kirkland) wrote :

Awesome feedback, Hannes. I'll get this solved ;-)

Changed in byobu:
status: Incomplete → In Progress
assignee: nobody → Dustin Kirkland (kirkland)
Dustin Kirkland  (kirkland) wrote :

Hannes, can you take a look at my Comment #2 and get me some feedback on making that change?

Dustin Kirkland  (kirkland) wrote :

Hannes, one more request, could you try the latest byobu version from Oneiric? You can safely just download and install the Oneiric deb from:

Changed in byobu:
status: In Progress → Incomplete

Had similar problems on CentOS5, with both Byobu-4.1/4.29. I tracked the issue down to the shell environment aliases for ls, normally "ls --color=tty" on this OS, not being set inside Byobu sessions.

This appears to be due to the behaviour of the /etc/profile.d/colorls scripts and the fact that Byobu sets defbce in its Screen config, this results in TERM=screen-bce which is itself not listed in /etc/DIR_COLORS, and so the alias is never set. Commenting out the defbce setting in share/byobu/profiles/common fixes it without any side effects that I have noticed.

Dustin Kirkland  (kirkland) wrote :

To anyone having this problem...

Could you try the suggestions in Comment #9?

First, try "ls --color=tty" and see if you get the colors you want.

Second, try commending out "defbce on" in your ~/.byobu/profile.

Daniel Hahler (blueyed) wrote :

Shouldn't it be fixed with byobu 3.5-0ubuntu1 (comment #5)?

Dustin Kirkland  (kirkland) wrote :

Daniel, well, he downgraded from 3.33 to 3.5.

Hannes Koller (hannes-koller) wrote :


interestingly commenting out the dbfce setting does NOT fix byobu for me (tested on Ubuntu 11.04 and Ubuntu 10.04).

BUT I recently found a very similar fix that works for me:

Edit /usr/share/byobu/profiles/common

comment out:
# attrcolor b ".I"
# termcapinfo xterm 'Co#256:AB=\E[48;5;%dm:AF=\E[38;5;%dm'

restart byobu.

Hope this helps :)

Dustin Kirkland  (kirkland) wrote :

Thanks, Hannes!

Changed in byobu:
status: Incomplete → Triaged
Dustin Kirkland  (kirkland) wrote :


Could you try, instead, adding this to your ~/.screenrc:

attrcolor b ""
termcapinfo xterm* ti@:te@

Changed in byobu:
status: Triaged → Incomplete
Hannes Koller (hannes-koller) wrote :

sorry for the late reply. I just tried your suggestion on Ubuntu 10.04 (byobu version 2.68-0ubuntu1.2 ) and it did not fix the problem (but commenting out the two lines from /etc/share/byobu/profiles/common does fix it)... will try on newer version when I find the time..

Dustin Kirkland  (kirkland) wrote :

Found some info here:

Bookmarking it for looking deeper later.

Rami Al-Ghanmi (alghanmi) wrote :

I did not notice much of a difference in directory listings, however, there is a significant different when using vim. In the attached screenshot, you see two instances of the same vim configuration. One of them using byobu and the other one is not.

I attempted the fixes in #2, #13, #15 with no success. I am running:
* Ubuntu 10.04.4 LTS
* byobu 5.17
* tmux 1.5
* vim 7.2 (including patches 1-330)

For reference, this is the Solarized vim repo:

Rami Al-Ghanmi (alghanmi) wrote :

I was able to fix this by adding the following line to my .bashrc

export TERM="xterm-256color"

Changed in byobu:
status: Incomplete → Fix Committed
Changed in byobu:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers