Computing.Net > Forums > Solaris > How to Set PS1 prompt

How to Set PS1 prompt

Reply to Message Icon

Original Message
Name: Rajesh
Date: November 18, 2003 at 13:00:55 Pacific
Subject: How to Set PS1 prompt
OS: SunOS par1unixdb01 5.8 Ge
CPU/Ram: 1Gb
Comment:

I am trying to setup PS1 on my server using PS1='$PWD : $LOGNAME >' ...but when I cd to a different directory then directory name is not reflected in the prompt. What am I missing.


Report Offensive Message For Removal


Response Number 1
Name: Denny Raab
Date: November 21, 2003 at 10:12:04 Pacific
Reply: (edit)

I am assuming that you are indeed using Korn Shell. Herre is what I use:

PS1="`uname -n` "'${PWD}> '


Report Offensive Follow Up For Removal







Use following form to reply to current message:

   Name: From My Computing.Net Settings
 E-Mail: From My Computing.Net Settings

Subject: How to Set PS1 prompt 

Comments:

 


  Homepage URL (*): 
Homepage Title (*): 
         Image URL: 
 
Data Recovery Software




Have you ever used OpenOffice?

Yes, as my main suite.
Yes, occationally.
Yes, but only once.
No, never.


View Results

Poll Finishes In 5 Days.
Discuss in The Lounge