elif answer == 'y':
print "Committing"
subst = {}
+ subst['__SUBJECT__'] = "Transitions completed: " + ", ".join(sorted(to_remove))
subst['__TRANSITION_MESSAGE__'] = "The following transitions were removed:\n"
- for remove in to_remove:
+ for remove in sorted(to_remove):
subst['__TRANSITION_MESSAGE__'] += info[remove] + '\n'
del transitions[remove]
subst['__DAK_ADDRESS__'] = Cnf["Dinstall::MyEmailAddress"]
subst['__BCC__'] = 'X-DAK: dak transitions'
if Cnf.has_key("Dinstall::Bcc"):
- subst["__BCC__"] += '\nBcc: %s' % Cnf["Dinstall:Bcc"]
+ subst["__BCC__"] += '\nBcc: %s' % Cnf["Dinstall::Bcc"]
message = utils.TemplateSubst(subst,
os.path.join(Cnf["Dir::Templates"], 'transition.removed'))
utils.send_mail(message)