On Sun Jun 14 14:12:13 PDT 2015, nsa...@gmail.com wrote:
> Why doesn't the plan9 test program have features for checking
> inequalities (i.e. greater than etc.)?
> What do you guys do when you want to test for inequality?
>
> Maybe the most convenient way to do that in the shell would be if I
> ma
> Oops :)
> Sorry, I didn't notice that there under the -eq entry.
ditto :-(
As I said, never used em.
-Steve
> Any of the comparisons -ne, -gt, -ge, -lt, or -le may be used in place of -eq.
Oops :)
Sorry, I didn't notice that there under the -eq entry.
Thanks
TEST(1) TEST(1)
NAME
test - set status according to condition
SYNOPSIS
test expr
DESCRIPTION
Test evaluates the expression expr. If the value is true the
exit status is null; otherwise t
It would be easy to extend test to add these features,
you could submit a patch if you feel strongly.
To be honest I have never had the need for inequalaties,
perhaps I have been lucky.
-Steve
Quoting Neven Sajko :
Why doesn't the plan9 test program have features for checking
inequalities (i.e. greater than etc.)?
What do you guys do when you want to test for inequality?
I use test(1) which does, in fact, support these features, as
described in the man page.
khm
Why doesn't the plan9 test program have features for checking
inequalities (i.e. greater than etc.)?
What do you guys do when you want to test for inequality?
Maybe the most convenient way to do that in the shell would be if I
made two tiny programs, lt & gt which would check their two arguments.