SPUG: aliases, -> Korn Shell vs. PD-ksh
William Julien
moonbeam at catmanor.com
Thu Jan 23 22:55:26 CST 2003
>
>I recommend downloading the binary-only version, because the
>source-code distribution has the weirdest installation procedure
>ever devised by man, and anybody having experience with conventional
>installation techniques will undoubtedly foul it up.
>
>Click on "ksh - standalone AT&T ksh executable" at
>http://www.research.att.com/sw/download/
I'm a big korn shell fan. I found that the installation can be very
simple by just putting ksh into /bin and edit the /etc/shells. All
the other stuff isn't necessary.
By the way, my .kshrc it contains:
PS1="-->"
#
# terminal and title bar status (interactive only)
#
case $- in
*i*)
if [ `whence _cd | wc -l` -eq 0 ]; then
function _cd
{
cd "$@"
/bin/echo -n "^[]2;$HOST:$PWD^G^[]1;$HOST^G"
}
alias cd=_cd
cd `pwd`
fi
export TERM=xterm
esac
The ^[ is an escape character and ^G is CTRL-G. This puts the path in the
xterm title bar and keeps my prompt a nice constant "-->".
---
William Julien _,'| _.-''``-...___..--';
moonbeam at catmanor.com /, \'. _..-' , ,--...--'''
vi is my shepherd; < \ .`--''' ` /|
i shall not font. `-,;' ; ; ;
__...--'' __...--_..' .;.'
(,__....----''' (,..--''
perl -e '( $ ,, $ ")=("a".."z")[0,-1]; print "sh", $ ","m\n";;";;"'
More information about the spug-list
mailing list