[Bash-completion-devel] Bug#551780: Fix by reading from avahi-browse with a timeout
Freddy Vulto
fvulto at gmail.com
Mon Mar 22 19:07:40 UTC 2010
Crestez Dan Leonard <cdleonard <at> gmail.com> writes:
> I had to mangle +o posix to get tests to pass. I don't know why the test
> suite puts the shell into posix mode anyway.
Because users 'out there' might run bash-completion in bash POSIX mode. I
regard POSIX as just stricter bash script and supportable with little effort, so
I put it in the test suite to make sure bash-completion honours POSIX. A
notable error is that POSIX doesn't allow a hyphen (-) in a function name,
whereas standard bash does allow:
$ f-a() { echo foo; }
$ set -o posix
$ f-a() { echo foo; }
bash: `f-a': not a valid identifier
Perhaps the test suite should test completions both with and without POSIX
mode...
Another solution - if bash-completion really demands noPOSIX :-( - could be to
disable POSIX on entering bash-completion and restore POSIX (if it was enabled)
on exit, but this 'on exit' is hard to catch...
Greetings,
Freddy Vulto
http://fvue.nl
More information about the Bash-completion-devel
mailing list