requirements.txt, new IRC server, SSL default

This commit is contained in:
nikolark committed 2014-05-14 15:30:11 +02:00
1 parent 5f570ac9b8
commit 9a0d45c3f6
4 files changed
+11 -5

No files matched your search

+1
View File
@@ -1,3 +1,4 @@
settings.py
*.swp
*.pyc
venv
+1 -1
View File
@@ -1,5 +1,5 @@
Requirements:
- python-twisted
- python-twisted python-mysqldb python-lxml python-openssl
$ python snurr.py -h
Usage: python snurr.py [options] CHANNEL
+5
View File
@@ -0,0 +1,5 @@
MySQL-python==1.2.5
Twisted==14.0.0
lxml==3.3.5
service-identity==0.2
pyOpenSSL==0.14
+4 -4
View File
@@ -188,7 +188,7 @@ class IRCActions():
reply = "URL: "
url = urlmatch.group()
try:
i = urllib2.urlopen(url, timeout=3)
i = urllib2.urlopen(url, timeout=3, headers={'User-Agent': 'snurrbot v0.1'})
except Exception as e:
_log(e)
self.bot.msgReply(nick, channel, reply + "Timeout")
@@ -276,11 +276,11 @@ def _setup_and_parse_options():
parser = optparse.OptionParser(description='Pipes UDP-messages to an IRC-channel.',
usage=_usage())
parser.add_option('-c', '--connect', metavar='SERVER',
help='IRC server (default: irc.ifi.uio.no)', default='irc.ifi.uio.no')
help='IRC server (default: irc.ifi.uio.no)', default='irc.oftc.net')
parser.add_option('-p', '--port', metavar='PORT', type=int,
help='IRC server port (default: 6667)', default=6667)
help='IRC server port (default: 6697)', default=6697)
parser.add_option('-s','--ssl', action='store_true',
help='connect with SSL (default: False)', default=False)
help='connect with SSL (default: False)', default=True)
parser.add_option('-l', '--listen_port', metavar='LISTEN_PORT', type=int,
help='UDP listen port (default: 55666)', default=55666)
return parser.parse_args()