ThirdParty/Pygments/pygments/lexers/automation.py

changeset 4697
c2e9bf425554
parent 4172
4f20dba37ab6
child 5713
6762afd9f963
equal deleted inserted replaced
4696:bf4d19a7cade 4697:c2e9bf425554
3 pygments.lexers.automation 3 pygments.lexers.automation
4 ~~~~~~~~~~~~~~~~~~~~~~~~~~ 4 ~~~~~~~~~~~~~~~~~~~~~~~~~~
5 5
6 Lexers for automation scripting languages. 6 Lexers for automation scripting languages.
7 7
8 :copyright: Copyright 2006-2014 by the Pygments team, see AUTHORS. 8 :copyright: Copyright 2006-2015 by the Pygments team, see AUTHORS.
9 :license: BSD, see LICENSE for details. 9 :license: BSD, see LICENSE for details.
10 """ 10 """
11 11
12 from pygments.lexer import RegexLexer, include, bygroups, combined 12 from pygments.lexer import RegexLexer, include, bygroups, combined
13 from pygments.token import Text, Comment, Operator, Name, String, \ 13 from pygments.token import Text, Comment, Operator, Name, String, \
314 @windowsdir @workingdir @yday @year""".split() 314 @windowsdir @workingdir @yday @year""".split()
315 315
316 tokens = { 316 tokens = {
317 'root': [ 317 'root': [
318 (r';.*\n', Comment.Single), 318 (r';.*\n', Comment.Single),
319 (r'(#comments-start|#cs).*?(#comments-end|#ce)', Comment.Multiline), 319 (r'(#comments-start|#cs)(.|\n)*?(#comments-end|#ce)',
320 Comment.Multiline),
320 (r'[\[\]{}(),;]', Punctuation), 321 (r'[\[\]{}(),;]', Punctuation),
321 (r'(and|or|not)\b', Operator.Word), 322 (r'(and|or|not)\b', Operator.Word),
322 (r'[$|@][a-zA-Z_]\w*', Name.Variable), 323 (r'[$|@][a-zA-Z_]\w*', Name.Variable),
323 (r'!=|==|:=|\.=|<<|>>|[-~+/*%=<>&^|?:!.]', Operator), 324 (r'!=|==|:=|\.=|<<|>>|[-~+/*%=<>&^|?:!.]', Operator),
324 include('commands'), 325 include('commands'),

eric ide

mercurial