Show More
@@ -1441,7 +1441,6 b' class changeset_templater(changeset_prin' | |||||
1441 | props['cache'] = self.cache |
|
1441 | props['cache'] = self.cache | |
1442 |
|
1442 | |||
1443 | # find correct templates for current mode |
|
1443 | # find correct templates for current mode | |
1444 |
|
||||
1445 | tmplmodes = [ |
|
1444 | tmplmodes = [ | |
1446 | (True, None), |
|
1445 | (True, None), | |
1447 | (self.ui.verbose, 'verbose'), |
|
1446 | (self.ui.verbose, 'verbose'), | |
@@ -1449,15 +1448,14 b' class changeset_templater(changeset_prin' | |||||
1449 | (self.ui.debugflag, 'debug'), |
|
1448 | (self.ui.debugflag, 'debug'), | |
1450 | ] |
|
1449 | ] | |
1451 |
|
1450 | |||
1452 | types = {'header': '', 'footer':'', 'changeset': 'changeset'} |
|
1451 | types = {'header': '', 'footer': '', 'changeset': 'changeset'} | |
1453 |
for mode, postfix |
|
1452 | for mode, postfix in tmplmodes: | |
1454 | for type in types: |
|
1453 | for type in types: | |
1455 | cur = postfix and ('%s_%s' % (type, postfix)) or type |
|
1454 | cur = postfix and ('%s_%s' % (type, postfix)) or type | |
1456 | if mode and cur in self.t: |
|
1455 | if mode and cur in self.t: | |
1457 | types[type] = cur |
|
1456 | types[type] = cur | |
1458 |
|
1457 | |||
1459 | try: |
|
1458 | try: | |
1460 |
|
||||
1461 | # write header |
|
1459 | # write header | |
1462 | if types['header']: |
|
1460 | if types['header']: | |
1463 | h = templater.stringify(self.t(types['header'], **props)) |
|
1461 | h = templater.stringify(self.t(types['header'], **props)) | |
@@ -1477,7 +1475,6 b' class changeset_templater(changeset_prin' | |||||
1477 | if not self.footer: |
|
1475 | if not self.footer: | |
1478 | self.footer = templater.stringify(self.t(types['footer'], |
|
1476 | self.footer = templater.stringify(self.t(types['footer'], | |
1479 | **props)) |
|
1477 | **props)) | |
1480 |
|
||||
1481 | except KeyError as inst: |
|
1478 | except KeyError as inst: | |
1482 | msg = _("%s: no key named '%s'") |
|
1479 | msg = _("%s: no key named '%s'") | |
1483 | raise util.Abort(msg % (self.t.mapfile, inst.args[0])) |
|
1480 | raise util.Abort(msg % (self.t.mapfile, inst.args[0])) |
General Comments 0
You need to be logged in to leave comments.
Login now