from coalib.bearlib.abstractions.Linter import linter


@linter(executable='chktex',
        output_format='regex',
        output_regex=r'(?P<severity>Error|Warning) \d+ in .+ line '
                     r'(?P<line>\d+): (?P<message>.*)')
class LatexLintBear:
    """
    Checks the code with ``chktex``.
    """
    LANGUAGES = {"Tex"}
    AUTHORS = {'The coala developers'}
    AUTHORS_EMAILS = {'coala-devel@googlegroups.com'}
    LICENSE = 'AGPL-3.0'

    @staticmethod
    def create_arguments(filename, file, config_file):
        return filename,

@@ -448,16 +448,58 @@
 GPL-3.0'
+%0A    CAN_DETECT = %7B'Syntax', 'Formatting'%7D
 %0A%0A    @s

Add CAN_DETECT