Comment 44 for bug 678421

Revision history for this message
Martin Pitt (pitti) wrote :

> . "$CONFIG_FILE" 2>"$ERR"
> OTOH, I suppose that switching to bash wouldn't be approved just like that. ;)

Bash's input redirection simply is way more powerful. Granted, bash takes a tad longer to start up, but any tee or other external program which you call in addition will probably hurt performance just as much.

TBH I don't see a better solution either.

> You might think that something like this should work:
> . "$CONFIG_FILE" 2>&1 >/dev/null | tee "$ERR" >&2

No, as that would fork off the "." into a subprocess, and thus the exports only survive there.