help-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Help-bash] if and [ ] equivalence


From: Bill Gradwohl
Subject: [Help-bash] if and [ ] equivalence
Date: Sun, 11 Mar 2012 09:00:28 -0600

If I have a function that can optionally accept parameters, I can write :

   if func ; then
and the equivalent can be said:

   [ func ] &&

If, however, func needs to have a passed parameter,
   [ func parm ] &&

fails with "unary operator expected"

Is there any way to specify the [ ] method with a passed parameter?

Thank You

--
Bill Gradwohl


reply via email to

[Prev in Thread] Current Thread [Next in Thread]