Hello, team, I've tried to simplify construction below, which is sample of Andrey's ant script, and end up with following regular expression which matches string containing particular OS identifier or strings w/o any OS identifiers:
".*([_\\W]${env.OS}[_\\W].*$|.*(?<!.*[\\W_](win|lin|sol)[\\W_].*)$)" This would work fine with regex package from HARMONY-39 contribution, but fail to compile with SUN's classes (PatternSyntaxException: Look-behind group does not have an obvious maximum length, I would appreciate if someone point me to the place in any regex specification, stating that it's valid behavior). >From the compatibility point of view this enhancement is no good, but to give a hint how to implement negative assertions in terms of regex negative look behind/ahead is the solution. > <propertyregex property="OS.match" input="@{file}" > regexp="[\W_]${env.OS}[\W_]" override="yes" defaultValue="no" > select="yes"/> > <propertyregex property="OS.any.match" input="@{file}" > regexp="[\W_](win|linux|solaris)[\W_]" override="yes" > defaultValue="no" select="yes"/> > <istrue value="${OS.match}"/> > <not> > <istrue value="${OS.any.match}"/> > </not> Thank you. Nikolay Kuznetsov Intel Middleware Products Division