2010-07-24 09:54:38 -05:00
|
|
|
#!/usr/bin/env python3.1
|
|
|
|
|
2010-07-24 10:12:00 -05:00
|
|
|
from configparser import *
|
2010-07-24 09:54:38 -05:00
|
|
|
import os
|
2010-07-24 10:12:00 -05:00
|
|
|
import sys
|
2010-07-24 09:54:38 -05:00
|
|
|
|
2010-07-24 10:12:00 -05:00
|
|
|
config = ConfigParser()
|
2010-07-24 09:54:38 -05:00
|
|
|
config.read([os.path.expanduser('~/.dr.botzo.cfg'), 'dr.botzo.cfg'])
|
|
|
|
|
2010-07-24 10:12:00 -05:00
|
|
|
try:
|
|
|
|
# load connection info
|
|
|
|
server = config.get('IRC', 'server')
|
|
|
|
port = config.getint('IRC', 'port')
|
|
|
|
channel = config.get('IRC', 'channel')
|
|
|
|
nick = config.get('IRC', 'nick')
|
|
|
|
ircname = config.get('IRC', 'name')
|
|
|
|
except NoSectionError as e:
|
|
|
|
sys.exit(str(e))
|
2010-07-24 09:54:38 -05:00
|
|
|
|
|
|
|
# vi:tabstop=4:expandtab:autoindent
|