Subject: Re: CVS commit: basesrc/bin/ksh
To: Joerg Klemenz <firstname.lastname@example.org>
From: Roland Dowdeswell <email@example.com>
Date: 09/28/2002 10:37:58
On 1033223597 seconds since the Beginning of the UNIX epoch
Joerg Klemenz wrote:
>Like I just told Mr. Woods, this one fails w/ both BASH and zsh and
>any other sh-compatible system that has a working $RANDOM.
>Thats exactly what I'm talking about. There is simply no reliable way
>to detect what sh one is running.
>Thats why every other shell except ksh uses its own *rc file for
>Just because its "POSIX" doesn't mean it makes any sense...
But, because generally bash and zsh use their own startup scripts
it shouldn't come up in practice. Simon only suggested this as a
mechanism of distinguishing the two shells which share .profile.
There really aren't all that many ksh-specific things that you
generally want to do in your startup scripts, are there? The only
thing that I do is set -o vi-tabcomplete and that is pdksh-specific
not just ksh-specific. And for that I just do a feature-set test
rather than a shell test:
case $- in *i*)
set -o vi
if set -o | grep vi-tabcomplete >/dev/null 2>&1; then
set -o vi-tabcomplete
Roland Dowdeswell http://www.Imrryr.ORG/~elric/