Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Need system name included in command line prompt 1

Status
Not open for further replies.
Nov 29, 2001
20
0
0
US
For the life of me I cannot remember how to set this up.

I have a client with 2 SCO 505 Enterprise systems connected to a KVM (Keyboard, Video, Mouse) switch. It is difficult at times to remember which system you are working with. I need to put names for each system in the command line prompt to readily identify which system is being worked on. For example, I need the command line prompt to look something like this:
"LADS #"
OR
"# LADS"

Can anyone refresh my memory on how this is done?

Thanks;
Mike
 
Put something like the following in your .profile:

PS1=`uname -n`# ; export PS1

This will give you your system name in your prompt. HTH.
 
you can of course put anything you want in the PS1= parameter. If uname -n isn't the name you want. for instance...

PS1="LADS # " ; export PS1
/Sören
 
Thanks Folks;

It worked and it helped.

You know the old saying "If you don't use it, You lose it." Guess that was true for me.

Thanks again;
Mike
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top