On Sun, Aug 27, 2006 at 11:22:13AM +0200, Martin Toft wrote:
> Sam Chill wrote:
> >ksh does most everything bash does too, so it doesn't seem like a loss.
>
> FWIW, I miss a couple of features in ksh and consider to switch (back)
> to bash:
>
> - When using tab completion, and you press tab two times to get a list
> of possibilities, ksh doesn't use less/more to present the possibilities
> (i.e. they just scroll by and I have to use shift+page-up).
>
> - When writing long commands, bash uses multiple lines to let me see the
> whole command, whereas ksh "scrolls" the line horizontally, only showing
> me a part of the command at a time. This is of course a matter of taste,
> but I like the method of bash.
These are features of readline, which bash uses. You can toggle them on
and off in your ~/.inputrc file. I tend to prefer pdksh and usually
configure readline to mimic it when I have to use bash.
set page-completions off
set horizontal-scroll-mode on
One feature that is very annoying with bash is how it handles $BASH_ENV
and $ENV. Some of bash's behavior appears to be specified at compile
time, and I don't think I have ever seen two systems with bash compiled
the same way. You usually find something like this snippet in the
default installed .profile (or .bash_profile) on linux systems:
if [ -f ~/.bashrc ] ; then
. ~/.bashrc
fi
What is annoying about this is that .bashrc isn't read everytime a shell
is started, only at login. So, some other programs may need extra hacks
to read your environment file correctly (ie. setting XTerm*loginShell
to true).
I find this so much more simple and it always works consistently for
pdksh.
export ENV=~/.kshrc
I don't have to do funny tricks in various programs to simulate a login
shell. I can use su to change privileges and keep my environment much
more conveniently. For bash, you have to figure out how it was compiled
first. No thanks.