[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [bug-grep] bashism in egrep
From: |
Andreas Schwab |
Subject: |
Re: [bug-grep] bashism in egrep |
Date: |
Sat, 19 Feb 2005 16:01:44 +0100 |
User-agent: |
Gnus/5.110002 (No Gnus v0.2) Emacs/22.0.50 (gnu/linux) |
Han Boetes <address@hidden> writes:
> Hi,
>
> egrep contains a bashism:
No.
>
> #!/bin/sh
> exec grep -E ${1+"$@"}
This is plain Bourne and POSIX shell syntax.
> with zsh as the sh implementation you'll get:
>
> egrep 'blah blah' /dev/null
> egrep: no such file or directory: blah
The sh emulation of zsh is broken.
Andreas.
--
Andreas Schwab, SuSE Labs, address@hidden
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."