dr.botzo/dr.botzo.py

21 lines
495 B
Python
Raw Normal View History

2010-07-24 09:54:38 -05:00
#!/usr/bin/env python3.1
from configparser import *
2010-07-24 09:54:38 -05:00
import os
import sys
2010-07-24 09:54:38 -05:00
config = ConfigParser()
2010-07-24 09:54:38 -05:00
config.read([os.path.expanduser('~/.dr.botzo.cfg'), 'dr.botzo.cfg'])
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