Yocto Project Discussions
 help / color / mirror / Atom feed
* [AUH][PATCH 1/2] emailhandler: actually send messages to cc_list as well
@ 2020-06-30  9:09 Alexander Kanavin
  2020-06-30  9:09 ` [AUH][PATCH 2/2] upgradehelper: use a separate setting for CCing recipe upgrades Alexander Kanavin
  0 siblings, 1 reply; 2+ messages in thread
From: Alexander Kanavin @ 2020-06-30  9:09 UTC (permalink / raw)
  To: yocto; +Cc: Alexander Kanavin

Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
---
 modules/utils/emailhandler.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/modules/utils/emailhandler.py b/modules/utils/emailhandler.py
index 066f013..8c8b85b 100644
--- a/modules/utils/emailhandler.py
+++ b/modules/utils/emailhandler.py
@@ -103,6 +103,8 @@ class Email(object):
         try:
             smtp = SMTP(self.smtp_host, self.smtp_port)
             smtp.sendmail(self.from_addr, to_addr, msg_text)
+            if cc_addr is not None:
+                smtp.sendmail(self.from_addr, cc_addr, msg_text)
             smtp.close()
         except Exception as e:
             E("Could not send email: %s" % str(e))
-- 
2.27.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [AUH][PATCH 2/2] upgradehelper: use a separate setting for CCing recipe upgrades
  2020-06-30  9:09 [AUH][PATCH 1/2] emailhandler: actually send messages to cc_list as well Alexander Kanavin
@ 2020-06-30  9:09 ` Alexander Kanavin
  0 siblings, 0 replies; 2+ messages in thread
From: Alexander Kanavin @ 2020-06-30  9:09 UTC (permalink / raw)
  To: yocto; +Cc: Alexander Kanavin

Previously it was same as status update recipients.

Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
---
 upgrade-helper.conf | 3 +++
 upgradehelper.py    | 4 ++--
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/upgrade-helper.conf b/upgrade-helper.conf
index 98ef58f..e926300 100644
--- a/upgrade-helper.conf
+++ b/upgrade-helper.conf
@@ -31,6 +31,9 @@
 # except when recipes are owned by specific maintainer_override entries above.
 #global_maintainer_override=john.doe@doe.com
 
+# who should be CCd with all upgrade emails (optional)
+#cc_recipients=john.doe@doe.com
+
 # who should get the status mail with statistics, at the end (optional)
 #status_recipients=john.doe@doe.com
 
diff --git a/upgradehelper.py b/upgradehelper.py
index 061d18d..c2480f1 100755
--- a/upgradehelper.py
+++ b/upgradehelper.py
@@ -321,8 +321,8 @@ class Updater(object):
             to_addr = pkg_ctx['MAINTAINER']
 
         cc_addr = None
-        if "status_recipients" in settings:
-            cc_addr = settings["status_recipients"].split()
+        if "cc_recipients" in settings:
+            cc_addr = settings["cc_recipients"].split()
 
         newversion = pkg_ctx['NPV'] if not pkg_ctx['NPV'].endswith("new-commits-available") else pkg_ctx['NSRCREV']
         subject = "[AUH] " + pkg_ctx['PN'] + ": upgrading to " + newversion
-- 
2.27.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-06-30  9:09 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-06-30  9:09 [AUH][PATCH 1/2] emailhandler: actually send messages to cc_list as well Alexander Kanavin
2020-06-30  9:09 ` [AUH][PATCH 2/2] upgradehelper: use a separate setting for CCing recipe upgrades Alexander Kanavin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox