From 7ff36d8aad7182a82c7e6270ea393c46fe56a310 Mon Sep 17 00:00:00 2001 From: gutosie Date: Tue, 19 May 2020 20:38:21 +0300 Subject: [PATCH] up 9.01 --- NeoBoot/plugin.py | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/NeoBoot/plugin.py b/NeoBoot/plugin.py index 9514c0b..0930c6e 100644 --- a/NeoBoot/plugin.py +++ b/NeoBoot/plugin.py @@ -50,8 +50,8 @@ if fileExists('/etc/vtiversion.info') and fileExists('/.multinfo'): else: from files.neoconsole import Console -PLUGINVERSION = '9.01' -UPDATEVERSION = '9.01' +PLUGINVERSION = '9.00' +UPDATEVERSION = '9.00' LinkNeoBoot = '/usr/lib/enigma2/python/Plugins/Extensions/NeoBoot' try: @@ -1010,16 +1010,23 @@ class NeoBootImageChoose(Screen): os.system('cd /tmp;fullwget --no-check-certificate https://codeload.github.com/gutosie/NeoBoot-9/zip/master; mv /tmp/master /tmp/neoboot.zip; sleep 3;cd ') if not fileExists('/tmp/neoboot.zip'): self.session.open(MessageBox, _('Unfortunately, at the moment not found an update, try again later.'), MessageBox.TYPE_INFO, 8) - else: + else: + self.goUpdateNEO() + else: + self.goUpdateNEO() + else: + os.system('rm -f ' + LinkNeoBoot + '/ver.txt') + self.session.open(MessageBox, _('The update has been canceled.'), MessageBox.TYPE_INFO, 8) + + def goUpdateNEO(self): + if fileExists('' + LinkNeoBoot + '/wget-log'): + os.system('rm ' + LinkNeoBoot + '/wget-log') os.system('cd /tmp/; unzip -qn ./neoboot.zip; rm -f ./neoboot.zip; cp -rf ./NeoBoot-9-master/NeoBoot /usr/lib/enigma2/python/Plugins/Extensions; rm -rf /tmp/NeoBoot-9-master; rm ' + LinkNeoBoot + '/ver.txt; cd ' + LinkNeoBoot + '/; chmod 0755 ./bin/neoini*; chmod 0755 ./ex_init.py; chmod 0755 ./tmpfiles/target/*; chmod 0755 ./files/NeoBoot.sh; chmod 0755 ./files/userscript.sh; cd') if getCPUtype() == 'MIPS': os.system('cd ' + LinkNeoBoot + '/; cp -rf ./bin/neoinitmipsvu /sbin; chmod 755 /sbin/neoinitmipsvu; cp -rf ./bin/neoinitmips /sbin; chmod 755 /sbin/neoinitmips; cd') os.system('cd ' + LinkNeoBoot + '/; rm ./bin/install; rm ./files/mountpoint.sh; rm ./files/neo.sh') restartbox = self.session.openWithCallback(self.restartGUI, MessageBox, _('Completed update NeoBoot. You need to restart the E2 !!!\nRestart now ?'), MessageBox.TYPE_YESNO) restartbox.setTitle(_('Restart GUI now ?')) - else: - os.system('rm -f ' + LinkNeoBoot + '/ver.txt') - self.session.open(MessageBox, _('The update has been canceled.'), MessageBox.TYPE_INFO, 8) def restartGUI(self, answer): if answer is True: