Uncategorized

rpi stk admin

For your high reputation, you should understand the difference, ….

No colors in terminal when booting raspbian in text mode [on hold]

-5

I am booting my pi as text with autologin.

Even after modifying the bashrc file in the /home/pi folder, I still see the text in white. I know that the color is enabled, because during the boot, I see the OK in green, so the terminal seems enabled for color, but nothing show up when I run ls -la or other commands.

What am I missing? I did enable force_color_prompt=yes in bashrc; and uncommented the lines where the aliases include the --color=autol but still nothing happen.

put on hold as off-topic by Milliwaysgoldilocks 2 days ago

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • “This question does not appear to be specific to the Raspberry Pi within the scope defined in the help center.” – goldilocks

If this question can be reworded to fit the rules in the help center, please edit the question.

  • 1
    what response does echo $TERM get you? – Jasen 2 days ago
  • your question has nothing to do with the RPi … it is a Linux question …. research debian linux terminal colors– jsotola 2 days ago
  • @jsotola please point me to where I said that this was a RPI issue. Please take time to read a question, if you are going to reply. – rataplan 2 days ago
  • 1
    there’s probalby more skill to address this problem in the “unix and linux” stack exchange as the TERM variable is common to all of that. it supposed to be automatically set , but I am not sure how that is meant to happen. – Jasen 2 days ago

2

The terminal emulation also plays a role with colors on the text console. I just don’t know how it is set by default because I set it always to linux. You can get your setting with:

rpi ~$ echo $TERM

Try to set it in ~/.profile as first command:

TERM=linux

then logout/logon and look if it helps.

  • Thanks, I will try this out today. As now the $TERM variable is empty – rataplan 2 days ago
  • Hi @Jasen, you tried to add ´export TERM` to the answer. Sorry, but I haven’t accepted it because it is not needed. ~/.profile is a login file similar to ~/.bashrc. It is sourced to the calling bash so there is no need to export environment variables when set in ~/.profile. – Ingo 2 days ago
  • @rataplan, Just now I did the following: (1) login to GUI DeskTpo, (2) switch to text terminal <ctrl-alt-F1>, (3) ls -la and saw a colourful list. imgur.com/gallery/dn18IJB Does it mean my config (rpi3B=, stretch 9) can do what your config cannot do? – tlfong01 yesterday    
  • @rataplan, I also booted to CLI, and found “$ ls -la” colourful. “$ who” replied “pi tty1, …” tlfong01 2019jun18hkt1559 – tlfong01 yesterday   

Not the answer you’re looking for? Browse other questions tagged  or ask your own question.

Categories: Uncategorized

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: