diff options
author | Zac Medico <zmedico@gentoo.org> | 2008-03-28 12:43:12 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2008-03-28 12:43:12 +0000 |
commit | c1a6c5981162b495003a1c73e3131da0704ab13a (patch) | |
tree | 4575476703962950ae90f47a999686a7245dfa39 /pym | |
parent | df269fa89f00eacabf855b88ce0dcf5add6b8fd6 (diff) | |
download | portage-c1a6c5981162b495003a1c73e3131da0704ab13a.tar.gz portage-c1a6c5981162b495003a1c73e3131da0704ab13a.tar.bz2 portage-c1a6c5981162b495003a1c73e3131da0704ab13a.zip |
Support ${HOST} substitution in "From" field. Thanks to wschlich.
(trunk r9510)
svn path=/main/branches/2.1.2/; revision=9570
Diffstat (limited to 'pym')
-rw-r--r-- | pym/elog_modules/mod_mail.py | 1 | ||||
-rw-r--r-- | pym/elog_modules/mod_mail_summary.py | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/pym/elog_modules/mod_mail.py b/pym/elog_modules/mod_mail.py index 058faa7c0..01771262d 100644 --- a/pym/elog_modules/mod_mail.py +++ b/pym/elog_modules/mod_mail.py @@ -14,6 +14,7 @@ def process(mysettings, cpv, logentries, fulltext): myrecipient = "root@localhost" myfrom = mysettings["PORTAGE_ELOG_MAILFROM"] + myfrom = myfrom.replace("${HOST}", socket.getfqdn()) mysubject = mysettings["PORTAGE_ELOG_MAILSUBJECT"] mysubject = mysubject.replace("${PACKAGE}", cpv) mysubject = mysubject.replace("${HOST}", socket.getfqdn()) diff --git a/pym/elog_modules/mod_mail_summary.py b/pym/elog_modules/mod_mail_summary.py index 339b4b827..50e8171df 100644 --- a/pym/elog_modules/mod_mail_summary.py +++ b/pym/elog_modules/mod_mail_summary.py @@ -39,6 +39,7 @@ def _finalize(mysettings, items): myrecipient = "root@localhost" myfrom = mysettings["PORTAGE_ELOG_MAILFROM"] + myfrom = myfrom.replace("${HOST}", socket.getfqdn()) mysubject = mysettings["PORTAGE_ELOG_MAILSUBJECT"] mysubject = mysubject.replace("${PACKAGE}", count) mysubject = mysubject.replace("${HOST}", socket.getfqdn()) |