public inbox for cygwin-apps-cvs@sourceware.org
help / color / mirror / Atom feed
* [calm - Cygwin server-side packaging maintenance script] branch master, updated. 20210408-16-ga478607
@ 2021-05-20 14:03 Jon TURNEY
  0 siblings, 0 replies; only message in thread
From: Jon TURNEY @ 2021-05-20 14:03 UTC (permalink / raw)
  To: cygwin-apps-cvs




https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/calm.git;h=a478607b1706a2184090e31ba74ce0569333cd06

commit a478607b1706a2184090e31ba74ce0569333cd06
Author: Jon Turney <jon.turney@dronecode.org.uk>
Date:   Thu May 20 14:56:07 2021 +0100

    Have irkerd send our messages to libera.chat as well

https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/calm.git;h=79d4099c2d6a4000302bdb1662dd4c8b1661dac9

commit 79d4099c2d6a4000302bdb1662dd4c8b1661dac9
Author: Jon Turney <jon.turney@dronecode.org.uk>
Date:   Thu May 20 14:55:25 2021 +0100

    Allow 'orphaned package maintainers' to run untest on them


Diff:
---
 calm/irk.py    | 22 +++++++++++++---------
 calm/untest.py |  2 +-
 2 files changed, 14 insertions(+), 10 deletions(-)

diff --git a/calm/irk.py b/calm/irk.py
index 5dd195d..40986b9 100755
--- a/calm/irk.py
+++ b/calm/irk.py
@@ -12,7 +12,7 @@ import socket
 import sys
 
 DEFAULT_SERVER = ("localhost", 6659)
-DEFAULT_TARGET = 'cygwin-bots'
+DEFAULT_TARGET = ['cygwin-bots', 'irc://irc.libera.chat/cygwin-bots']
 
 
 def connect(server=DEFAULT_SERVER):
@@ -26,16 +26,20 @@ def send(s, target, message):
 
 
 def irk(message, target=DEFAULT_TARGET, server=DEFAULT_SERVER):
-    try:
-        s = connect(server)
-        if "irc:" not in target and "ircs:" not in target:
-            target = "irc://chat.freenode.net/{0}".format(target)
+    if not isinstance(target, list):
+        target = [target]
+
+    for t in target:
+        try:
+            s = connect(server)
+            if "irc:" not in t and "ircs:" not in t:
+                t = "irc://chat.freenode.net/{0}".format(t)
 
-        send(s, target, message)
+            send(s, t, message)
 
-        s.close()
-    except OSError:
-        pass
+            s.close()
+        except OSError:
+            pass
 
 
 def main():
diff --git a/calm/untest.py b/calm/untest.py
index b749c15..48a3446 100644
--- a/calm/untest.py
+++ b/calm/untest.py
@@ -45,7 +45,7 @@ def untest(pvr):
     cygname = os.environ['CYGNAME']
 
     mlist = {}
-    mlist = maintainers.add_packages(mlist, common_constants.PKGMAINT)
+    mlist = maintainers.add_packages(mlist, common_constants.PKGMAINT, orphanMaint=common_constants.ORPHANMAINT)
 
     if cygname not in mlist:
         logging.error("'%s' is not a package maintainer" % (cygname))



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-05-20 14:03 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-20 14:03 [calm - Cygwin server-side packaging maintenance script] branch master, updated. 20210408-16-ga478607 Jon TURNEY

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).