Yuvipanda has submitted this change and it was merged.

Change subject: rm templates/misc/udpmxircecho.py.erb
......................................................................


rm templates/misc/udpmxircecho.py.erb

Unused duplicate of modules/mw-rc-irc/templates/udpmxircecho.py.erb

Change-Id: If3096de9b0616c2b5e2c2e15a9a12993fe062c06
---
D templates/misc/udpmxircecho.py.erb
1 file changed, 0 insertions(+), 64 deletions(-)

Approvals:
  Yuvipanda: Verified; Looks good to me, approved



diff --git a/templates/misc/udpmxircecho.py.erb 
b/templates/misc/udpmxircecho.py.erb
deleted file mode 100755
index e3ae28c..0000000
--- a/templates/misc/udpmxircecho.py.erb
+++ /dev/null
@@ -1,64 +0,0 @@
-#! /usr/bin/env python
-#
-# usage: mxircecho.py nickname server
-import sys
-
-from ircbot import SingleServerIRCBot
-import threading, socket
-
-class EchoReader(threading.Thread):
-       def __init__(self, bot):
-               threading.Thread.__init__(self)
-               self.abot = bot
-
-       def run(self):
-               udpsock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
-
-               udpsock.bind(('', 9390))
-
-               while True:
-                       try:
-                               s = udpsock.recv(65535)
-                               sp = s.split("\t")
-                               if len(sp) == 2:
-                                       channel = sp[0]
-                                       text = sp[1]
-                                       text = text.lstrip()
-
-                                       if channel not in bot.chans:
-                                               bot.chans.append(channel)
-                                               bot.connection.join(channel)
-
-
-                                       # this throws an exception if not 
connected.
-                                       bot.connection.privmsg(channel, text)
-                       except EOFError:
-                               # Once the input is finished, the bot should 
exit
-                               sys.exit()
-                       except:
-                               pass
-
-class EchoBot(SingleServerIRCBot):
-       def __init__(self, chans, nickname, server):
-               print "*** Connecting to IRC server %s..." % server
-               SingleServerIRCBot.__init__(self, [(server, 6667)], nickname, 
"IRC echo bot")
-               self.chans = chans
-
-       def on_nicknameinuse(self, c, e):
-               c.nick(c.get_nickname() + "_")
-
-       def on_welcome(self, c, e):
-               print "*** Connected"
-
-               # Get oper mode if we are connecting to browne
-               if c.get_server_name().endswith(".wikimedia.org"):
-                       c.oper("rc", "<%= udpmxircecho_pass %>")
-
-
-               for chan in self.chans:
-                       c.join(chan)
-       
-bot = EchoBot([], sys.argv[1], sys.argv[2]);
-sthr = EchoReader(bot)
-sthr.start()
-bot.start()

-- 
To view, visit https://gerrit.wikimedia.org/r/236499
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: If3096de9b0616c2b5e2c2e15a9a12993fe062c06
Gerrit-PatchSet: 2
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: Alex Monk <kren...@gmail.com>
Gerrit-Reviewer: Yuvipanda <yuvipa...@wikimedia.org>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to