1 from Wizard import Wizard, wizardManager
3 from Tools.Directories import fileExists
7 backupfile = "backupenigma2settings.tar"
9 def checkConfigBackup():
10 paths = ['/media/hdd/', '/media/cf/']
12 if fileExists(x + backupfile):
16 if checkConfigBackup() is None:
21 class ImageWizard(Wizard):
23 <screen position="0,0" size="720,576" title="Welcome..." flags="wfNoBorder">
24 <widget name="text" position="50,100" size="440,250" font="Regular;22" />
25 <widget name="list" position="50,350" zPosition="1" size="440,200" />
26 <widget name="config" position="50,350" zPosition="1" size="440,200" transparent="1" scrollbarMode="showOnDemand" />
29 def __init__(self, session):
30 self.xmlfile = "imagewizard.xml"
32 Wizard.__init__(self, session, showSteps=False, showStepSlider=False, showList=True, showConfig=True)
37 wizardManager.registerWizard(ImageWizard, backupAvailable)
40 os.system('tar cvpf ' + path + backupfile + ' /etc/enigma2')
43 os.system('cd / && /bin/tar xvpf ' + path + backupfile)