fix uppercase regex
Showing
2 changed files
with
3 additions
and
3 deletions
... | @@ -2,4 +2,4 @@ this a template file | ... | @@ -2,4 +2,4 @@ this a template file |
2 | 2 | ||
3 | var = [[{variable}]] | 3 | var = [[{variable}]] |
4 | 4 | ||
5 | otra_variable= [[{var}]] | ||
... | \ No newline at end of file | ... | \ No newline at end of file |
5 | otra_variable= [[{VAR}]] | ||
... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
... | @@ -15,8 +15,8 @@ class MyTemplate(string.Template): | ... | @@ -15,8 +15,8 @@ class MyTemplate(string.Template): |
15 | pattern = r''' | 15 | pattern = r''' |
16 | \[\[\{(?: | 16 | \[\[\{(?: |
17 | (?P<escaped>\[\[\{)| | 17 | (?P<escaped>\[\[\{)| |
18 | (?P<named>[_a-z][_a-z0-9]*)\}\]\]| | 18 | (?P<named>[_A-Z][_A-Z0-9]*)\}\]\]| |
19 | (?P<braced>[_a-z][_a-z0-9]*)\}\]\]| | 19 | (?P<braced>[_A-Z][_A-Z0-9]*)\}\]\]| |
20 | (?P<invalid>) | 20 | (?P<invalid>) |
21 | ) | 21 | ) |
22 | ''' | 22 | ''' | ... | ... |
-
Please register or sign in to post a comment