Skip to content

Commit

Permalink
Add missing config.py module
Browse files Browse the repository at this point in the history
  • Loading branch information
tronburgundy committed Feb 28, 2016
1 parent 6d3966c commit 3a47e7d
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions Version 0.2/config.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#!/usr/bin/python
'''
config.py
if a preferences.ini file is not found, create one. Otherwise, access
preference info.
'''

from configobj import ConfigObj

def accessconfig():
config = ConfigObj()
config.filename = './preferences.ini'

config['speedsound'] = 400.00
config['datapath'] = '~/acoustic_ruler/guiapp/'

config.write()

return config['speedsound'], config['datapath']

0 comments on commit 3a47e7d

Please sign in to comment.