Announcement

Collapse
No announcement yet.

Different terminal colors on diff hosts?

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Different terminal colors on diff hosts?

    I log in and out of multiple machines all day long via ssh. Can anyone show me how to set different terminal background colours on each machine? Would be helpful if I can log into pc2 and the terminal background becomes orange, pc3 and it becomes blue...etc. as a visual reminder of what pc I'm on.
    Thanks
    Dont pretend you havent noticed my cardboard box, Julia, because I know you have!

    #2
    Re: Different terminal colors on diff hosts?

    The environmental variable PS1 controls the prompt in a terminal, and can control it's colour.
    Code:
     echo $PS1
    will return the current prompt.

    There is a script at the bottom of this page that prints all the colours to screen so you can identify the code you need.

    Once you have crafted you new PS1, export it from your ~/.bashrc on the remote machine.

    Comment

    Working...
    X