[PATCH modular 2/2] Verify existence of command specified by --cmd.
Cyril Brulebois
kibi at debian.org
Sun Oct 24 00:00:33 PDT 2010
Trevor Woerner <twoerner at gmail.com> (23/10/2010):
> > I am not UNIX head, but it seems '$cmd1 > /dev/null 2>&1' would be
> > a more popular way to write this.
>
> Ha ha! Yes, that's how my fingers would more naturally phrase such a
> thing. But I *believe* that is a bash-ism.
It's not, it's just a redirection. I think what you could have in mind
is &>$n (used as a shortcut for >$n 2>&1). When in doubt, search for
“opengroup shell” and your favourite search engine will lead you to
what POSIX says.
That said, back to your original patch, you could just write:
| if which $arguments; then […]; fi
Mraw,
KiBi.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.x.org/archives/xorg-devel/attachments/20101024/efbd3911/attachment.pgp>
More information about the xorg-devel
mailing list