Score:0

How do I change the color of text on terminals?

tf flag

For some reason, I've lost all the colors on the terminal and all the text is in white as per the link below

enter image description here

I'm not entirely sure why it got changed automatically, but I'm not able to bring colors back to any of the terminals I've tried (default terminal, hyper, guake). So just that the location and username is in different color and I could tell them apart. Even in the image, ls -l showed everything in white whereas earlier it was showing folders in one particular color and files in one color.

I've tried to look for preferences in each of the terminal separately, but it seems to be some other setting that I may have changed accidentally.

sudodus avatar
jp flag
Which version of Ubuntu is it? Are you using bash (or some other command line interpreter)? Chick with `alias ls`, and if no (or error) output, try with `alias ls='ls --color=auto'`, and add that into your `"/.bashrc` file. If this is not the problem, please enter the settings menu of your terminal emulator and modify its settings (rendering colours might be turned off).
Michal Przybylowicz avatar
eg flag
Try `ls --color=always` does this display colors?
cc flag
Check that your .bashrc file is copied from /etc/skel/.bashrc. If you deleted your .bashrc, you would default back to the system default without all the color aliases.
Kush avatar
tf flag
So I've got Ubuntu 20.04.2 using ```ls --color=always``` I managed to add color to this command, but how would I be able to change the colors for the terminal text in general?
sudodus avatar
jp flag
What about `ls --color=auto` ? If it does not work, please replace `alias ls='ls --color=auto'` with `alias ls='ls --color=always'` in your bash configuration file `~/.bashrc`, run `source ~/.bashrc` and try `ls` again. (If for some reason there is no alias line for `ls` in your bash configuration file, please add it.)
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.