moved reading config to misc
This commit is contained in:
parent
bb02df97a6
commit
b4dae59394
|
@ -0,0 +1,13 @@
|
||||||
|
import configparser
|
||||||
|
import sys
|
||||||
|
|
||||||
|
iniConfig = configparser.ConfigParser()
|
||||||
|
iniConfig.read('config.ini')
|
||||||
|
|
||||||
|
try:
|
||||||
|
iniConfig['DATABASE']
|
||||||
|
except KeyError:
|
||||||
|
try:
|
||||||
|
iniConfig.read("../config.ini")
|
||||||
|
except KeyError:
|
||||||
|
iniConfig.read("../../config.ini")
|
Loading…
Reference in New Issue