Jonathan Nieder writes:
> Perhaps something like the following would work?
>
> tree-wide: convert test -a/-o to && and ||
>
> The interaction with unary operators and operator precedence
> for && and || are better known than -a and -o, and for that
> reason we prefer them.
Elia Pinto wrote:
> Even though POSIX.1 lists -a/-o as options to "test", they are
> marked "Obsolescent XSI". Scripts using these expressions
> should be converted as follow:
[... many lines snipped ...]
This is a very long description, and it doesn't leave me excited by
the change.
Is there s
I am very sorry : the comment is wrong. I will repost shortly.
Best regards
2014-05-15 16:17 GMT+02:00 Elia Pinto :
> Even though POSIX.1 lists -a/-o as options to "test", they are
> marked "Obsolescent XSI". Scripts using these expressions
> should be converted as follow:
>
> test "$1" -a "$2"
Even though POSIX.1 lists -a/-o as options to "test", they are
marked "Obsolescent XSI". Scripts using these expressions
should be converted as follow:
test "$1" -a "$2"
should be written as:
test "$1" && test "$2"
Likewise
test "$1" -o "$2"
should be written as:
test "$1" test "$2"
But n
4 matches
Mail list logo