NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: bin/43404: tab completion oddities in sh
The following reply was made to PR bin/43404; it has been noted by GNATS.
From: David Holland <dholland-bugs%netbsd.org@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc:
Subject: Re: bin/43404: tab completion oddities in sh
Date: Thu, 3 Jun 2010 01:55:31 +0000
On Wed, Jun 02, 2010 at 08:50:06AM +0000, Martin Husemann wrote:
> I can reproduce this, so it certainly isn't your setup.
...except that it is. The default /root/.shrc contains
if [ -f /etc/shrc ]; then
. /etc/shrc
fi
and /etc/shrc sets both -o emacs and -o tabcomplete.
The issue appears to be that (1) because su doesn't start a login
shell by default, it doesn't read /root/.profile, but a console root
login does, leading to differing behavior, (2) you need set -o emacs
as well as set -o tabcomplete for it to do anything, (3) several of my
machines were installed long enough ago that they don't have /etc/shrc
in place, and (4) when I checked /root/.profile and /root/.shrc point
#3 caused me to not look at the /etc/shrc on the newly installed
machines so I didn't see the set -o instances.
> Is /etc/shrc correct in running the set -o tabcomplete in a subshell?
Yes; it runs it both in and out of a subshell to avoid visible error
messages in ksh.
--
David A. Holland
dholland%netbsd.org@localhost
Home |
Main Index |
Thread Index |
Old Index