I am trying to use checkstyle to validate copyright header in my java code from a copyright header file.
<module name="RegexpHeader">
<property name="headerFile" value="${samedir}/somefile.header"/>
<property name="ignoreLines" value="10,11"/>
<property name="fileExtensions" value="java"/>
<property name="severity" value="error"/>
</module>
The copyright header is added to each java file as a multiline comment
/***************** \n
* Line 1 \n
* Line 2 \n
* Line 3 \n
*****************/
I am having issues with handling asterisk as a first character of the line. I need checkstyle to read first as is without considering it as a regex
I tried to escape the asterisk with * or \* but it does not work for me. Any clue?