Change terminal colors
Solved
trauqnej
Posted messages
162
Status
Member
-
trauqnej Posted messages 162 Status Member -
trauqnej Posted messages 162 Status Member -
Hello,
I have a computer that does not have a graphical interface.
I would like to change the text color and the background wallpaper.
I am using debian5.
My command echo $TERM indicates linux
How do I get a white background and black text?
(Or more broadly: where can I find the settings to change the colors?).
Regards,
Trauqnej
I have a computer that does not have a graphical interface.
I would like to change the text color and the background wallpaper.
I am using debian5.
My command echo $TERM indicates linux
How do I get a white background and black text?
(Or more broadly: where can I find the settings to change the colors?).
Regards,
Trauqnej
Configuration: debian5 iceweasel
5 answers
-
Hello,
Thank you for your two replies. I tried both of them and they are exactly what I was looking for.
Trauqnej -
If you want to color your prompt, it would be much more logical to intervene in /etc/bash.bashrc or in ~/.bashrc.
# set a fancy prompt (non-color, unless we know we "want" color) case "$TERM" in xterm-color) # PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ ' PS1='${debian_chroot:+($debian_chroot)}\[\033[01;33m\](\u@\h)\[\033[01;36m\] (\w) \$ \[\033[00m\]' ;; *) PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ ' ;; esac
You can add other terminals besides xterm-color (like xterm) because most support color.
Good luck. -
The terminal colors (background, etc.) are adjusted in the terminal settings. Depending on whether you are using a gnome terminal or a console, it may not be organized in exactly the same place, but generally, you just need to browse through the terminal menus to modify your current profile.
Good luck -
Hello,
unfortunately, as I mentioned earlier, my PC has no graphical interface.
Which would be equivalent to doing a [CTRL.ALT.F1]. (white text on a black background)
So, no menu. What I need is a command line.
Like this:
PS1="\[\033[0;37;44m\u@\033[1;32;43m\h:\033[0;33;41m\w$\033[0m\]"
seen on http://www.infos-du-net.com/forum/100879-10-shell-couleur
in a script named couleur.sh
that I would run whenever I wish.
But how do I get the background of the screen white? -
Hello,
You can use setterm.
example
setterm -background white -foreground blue -store
man setterm
setterm -h
Johan
--
Gates gave ^H sold you the windows.
GNU gave us the whole house. (Alexandrine)