Color Terminal screens and ssh revisited yet again

Sep 23, '05 06:34:00AM

Contributed by: the_shrubber

After at least five different hints on the matter, you may be getting sick of hearing about coloring your Terminal when you run ssh.

Well, relax! This hint actually reduces the number of total hints. JD Smith and I have collaborated to produce a joint version of our previous hints, ssh_host (link #2 above) and colorssh (#4 above). The new script is called colorwrap (2KB download) and includes the following features:

To use it, simply prefix your command with colorwrap, like this:
colorwrap ssh -X bubba@some.machine.com
I personally like to alias my ssh command to colorwrap ssh. You can also edit the script to customise the colors that get set. One handy trick is to use the GUI to the set the colors to taste, and then run the following command to find the relevant codes:
colorwrap getcolor
Use those codes when editing the file to set your own custom colors.

[robg adds: I tested the script, and it worked fine, though I chose to remove the .sh from the script's name ... and remember to use chmod a+x colorwrap to make it executable.]

Comments (10)


Mac OS X Hints
http://hints.macworld.com/article.php?story=20050920183403172