Skip to content

Commit

Permalink
Support new style coffee errors
Browse files Browse the repository at this point in the history
This fixes issue #398 by adding a regex to match the style of errors
that the latest version of coffee produces.
  • Loading branch information
Marcin Szczepanski committed Apr 1, 2013
1 parent f1f3a9f commit 7e960e6
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions sublimelinter/modules/coffeescript.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,10 @@ def parse_errors(self, view, errors, lines, errorUnderlines,
match = re.match(r'.*?Error: (?P<error>.+) '
r'on line (?P<line>\d+)', line)

if not match:
match = re.match(r'[^:]+:(?P<line>\d+):\d+: '
r'error: (?P<error>.+)', line)

if match:
line, error = match.group('line'), match.group('error')
self.add_message(int(line), lines, error, errorMessages)

0 comments on commit 7e960e6

Please sign in to comment.