Use t_Co=256 instead of setting TERM in .bashrc.