##// END OF EJS Templates
configitems: register the 'notify.maxsubject' config
Boris Feld -
r33743:3d08f481 default
parent child Browse files
Show More
@@ -173,6 +173,9 b" configitem('notify', 'fromauthor',"
173 configitem('notify', 'maxdiff',
173 configitem('notify', 'maxdiff',
174 default=300,
174 default=300,
175 )
175 )
176 configitem('notify', 'maxsubject',
177 default=67,
178 )
176
179
177 # template for single changeset can include email headers.
180 # template for single changeset can include email headers.
178 single_template = '''
181 single_template = '''
@@ -336,7 +339,7 b' class notifier(object):'
336 else:
339 else:
337 s = ctx.description().lstrip().split('\n', 1)[0].rstrip()
340 s = ctx.description().lstrip().split('\n', 1)[0].rstrip()
338 subject = '%s: %s' % (self.root, s)
341 subject = '%s: %s' % (self.root, s)
339 maxsubject = int(self.ui.config('notify', 'maxsubject', 67))
342 maxsubject = int(self.ui.config('notify', 'maxsubject'))
340 if maxsubject:
343 if maxsubject:
341 subject = util.ellipsis(subject, maxsubject)
344 subject = util.ellipsis(subject, maxsubject)
342 msg['Subject'] = mail.headencode(self.ui, subject,
345 msg['Subject'] = mail.headencode(self.ui, subject,
General Comments 0
You need to be logged in to leave comments. Login now