Enable saving on disk of saveddata. WARNING: This includes config changes, if you have custom config, be aware

This commit is contained in:
cncfanatics
2010-09-21 22:20:29 +02:00
parent bdd959d75f
commit a9d4ea7e24
2 changed files with 11 additions and 0 deletions

View File

@@ -6,4 +6,8 @@ debug = False
#Path autodetection, only change if it doesn't work
path = os.path.dirname(unicode(__file__, sys.getfilesystemencoding()))
homePath = os.path.expanduser(os.path.join("~", ".pyfa"))
saveddata = os.path.join(homePath, "saveddata.db")
# saveddata db location modifier, shouldn't ever need to touch this
import eos.config
eos.config.saveddata_connectionstring = "sqlite:///" + saveddata

7
run.py
View File

@@ -20,8 +20,15 @@
from gui.mainFrame import MainFrame
import wx
import config
import os.path
import eos.db
if __name__ == "__main__":
#Make sure the saveddata db exists
if not os.path.exists(config.saveddata):
eos.db.saveddata_meta.create_all()
pyfa = wx.App(False)
MainFrame()
pyfa.MainLoop()