Problem:
Whenever you open Workbench or the Eclipse Plug-in, you get this error message:
"Expression "*XXX*XXX*" invalid as a regular expression. Reason - Dangling meta character '*' near index 0"
When you click OK on the error it goes away and you can continue to work, but it is annoying. How can you get this error to stop displaying?
Error Message: "Expression "*XXX*XXX*" invalid as a regular expression. Reason - Dangling meta character '*' near index 0"
Environment:
CA Harvest SCM with Eclipse Plugin, all versions, Windows platform
Cause:
If you specify a Package Filter or Item search pattern that has an asterisk "*" as the first character, you will get this error. This is because filters and searches evaluate the search criteria as regular expressions (regex), and the meaning of a "*" is not the same in a regex as it is when you are matching file names at the command line.
Resolution:
You can fix this in a couple of ways.
For the Eclipse Plug-in, the file will be located at: "...\workspace\.metadata\.plugins\com.ca.harvest.team\dialog_settings.xml"
Additional Information:
Here is the rule for regular expressions:
A "*" is invalid at the beginning of a regex. A "*" means zero or more of the previous character. Since there is nothing previous to the first character, you cannot put a "*" at the beginning of a regex.