Minor point here, but inside of a character class block (\[square brackets\]), the asterisk has no special meaning, so it doesn't need escaping. `"^\\s(\\/\\*|###)[*!]\\s*$"`