tcsh fix

Roman Neuhauser neuhauser at chello.cz
Mon Nov 15 07:30:28 PST 2004


# ertr1013 at student.uu.se / 2004-11-12 04:11:22 +0100:
> The only real problem with having bash as /bin/sh is that people tend
> to write scripts using bash-specific features and forget that such
> scripts are not portable to systems using a less powerful /bin/sh.

    Or the other way around. Bash (at least the one from RHEL 3.0) is
    seriously broken, these two things are more than it can handle (as
    opposed to our /bin/sh):

    $(case $foo in
      x) do_x;;
      y) do_y;;
    esac)

    out=`mktemp ...`
    $otherscript >$out 2&1

    where $otherscript contains

    $(x | tee /dev/stderr | y)

    I stumbled upon these when I was porting periodic(8) to RHEL. So, my
    description would be that people run into problems when they write
    scripts using sh-specific features and forget that such scripts are
    not portable to systems using a less powerful bash. ;)


-- 
If you cc me or remove the list(s) completely I'll most likely ignore
your message.    see http://www.eyrie.org./~eagle/faqs/questions.html


More information about the freebsd-hackers mailing list