manipulating PS1 in sh
- From: "EdStevens" <quetico_man@xxxxxxxxx>
- Date: 27 Oct 2006 13:06:25 -0700
Trying to set PS1 to reflect the current value of a user environment
variable, when running in sh.
Most of my systems I am running in ksh, and my PS is set as follows:
export PS1=`hostname`'.''$ORACLE_SID> '
so that my prompt always shows the current value of $ORACLE_SID. But
it appears that this syntax doesn't yeild the same results with sh.
There, instead of returning the value of $ORACLE_SID, it simply returns
the literal "$ORACLE_SID".
The simple solution is to simply run ksh (my preference) but that
presents certain, uh, political challenges. Is there a simple way of
achieving this same functionality under sh (Solaris 5.9)?
.
- Follow-Ups:
- Re: manipulating PS1 in sh
- From: Jordan Abel
- Re: manipulating PS1 in sh
- Prev by Date: Re: cut
- Next by Date: Re: cut
- Previous by thread: scripting help
- Next by thread: Re: manipulating PS1 in sh
- Index(es):