Skip to content

Commit

Permalink
global settingsfile
Browse files Browse the repository at this point in the history
at first only read mode
  • Loading branch information
chaosblog committed Jan 24, 2012
1 parent ed571c4 commit 887b621
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions settings.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#!/usr/bin/python
import ConfigParser, os

def load_settings():
configfile = ConfigParser.ConfigParser()
configfile.read('settings.cfg')
config=dict()
config['mail']=configfile.get("general","mail")
config['start_date']=configfile.get("general","start_date")

config['username']=configfile.get("blogsettings","username")
config['xmlrpc_endpoint']=configfile.get("blogsettings","xmlrpc_endpoint")
config['blog_id']=configfile.get("blogsettings","blog_id")
config['participants_page_id']=configfile.get("blogsettings","participants_page_id")
return config

0 comments on commit 887b621

Please sign in to comment.