mirror of
https://github.com/gutosie/neoboot.git
synced 2025-11-03 12:45:47 +01:00
Add files via upload
This commit is contained in:
@@ -696,6 +696,9 @@ def RemoveUnpackDirs():
|
|||||||
elif os.path.exists('' + getNeoLocation() + 'ImagesUpload/hd51'):
|
elif os.path.exists('' + getNeoLocation() + 'ImagesUpload/hd51'):
|
||||||
rc = os.system('rm -r ' + getNeoLocation() + 'ImagesUpload/hd51')
|
rc = os.system('rm -r ' + getNeoLocation() + 'ImagesUpload/hd51')
|
||||||
|
|
||||||
|
elif os.path.exists('' + getNeoLocation() + 'ImagesUpload/bre2ze4k'):
|
||||||
|
rc = os.system('rm -r ' + getNeoLocation() + 'ImagesUpload/bre2ze4k')
|
||||||
|
|
||||||
|
|
||||||
elif os.path.exists('' + getNeoLocation() + 'ImagesUpload/multibox'):
|
elif os.path.exists('' + getNeoLocation() + 'ImagesUpload/multibox'):
|
||||||
rc = os.system('rm -r ' + getNeoLocation() + 'ImagesUpload/multibox')
|
rc = os.system('rm -r ' + getNeoLocation() + 'ImagesUpload/multibox')
|
||||||
@@ -1203,7 +1206,7 @@ def NEOBootExtract(source, target, ZipDelete):
|
|||||||
os.chdir('h9')
|
os.chdir('h9')
|
||||||
os.system('mv -f rootfs.ubi rootfs.bin')
|
os.system('mv -f rootfs.ubi rootfs.bin')
|
||||||
os.system('echo "Instalacja - ubi_reader w toku..."')
|
os.system('echo "Instalacja - ubi_reader w toku..."')
|
||||||
print '[NeoBoot] Extracting UBIFS image and moving extracted image to our target'
|
print ("[NeoBoot] Extracting UBIFS image and moving extracted image to our target")
|
||||||
cmd = 'chmod 777 ' + extensions_path + 'NeoBoot/ubi_reader/ubi_extract_files.py'
|
cmd = 'chmod 777 ' + extensions_path + 'NeoBoot/ubi_reader/ubi_extract_files.py'
|
||||||
rc = os.system(cmd)
|
rc = os.system(cmd)
|
||||||
cmd = 'python ' + extensions_path + 'NeoBoot/ubi_reader/ubi_extract_files.py rootfs.bin -o ' + getNeoLocation() + 'ubi'
|
cmd = 'python ' + extensions_path + 'NeoBoot/ubi_reader/ubi_extract_files.py rootfs.bin -o ' + getNeoLocation() + 'ubi'
|
||||||
@@ -1220,7 +1223,7 @@ def NEOBootExtract(source, target, ZipDelete):
|
|||||||
os.chdir('et10000')
|
os.chdir('et10000')
|
||||||
os.system('mv -f rootfs.bin rootfs.bin')
|
os.system('mv -f rootfs.bin rootfs.bin')
|
||||||
os.system('echo "Instalacja - ubi_reader w toku..."')
|
os.system('echo "Instalacja - ubi_reader w toku..."')
|
||||||
print '[NeoBoot] Extracting UBIFS image and moving extracted image to our target'
|
print ("[NeoBoot] Extracting UBIFS image and moving extracted image to our target")
|
||||||
cmd = 'chmod 777 ' + extensions_path + 'NeoBoot/ubi_reader/ubi_extract_files.py'
|
cmd = 'chmod 777 ' + extensions_path + 'NeoBoot/ubi_reader/ubi_extract_files.py'
|
||||||
rc = os.system(cmd)
|
rc = os.system(cmd)
|
||||||
cmd = 'python ' + extensions_path + 'NeoBoot/ubi_reader/ubi_extract_files.py rootfs.bin -o ' + getNeoLocation() + 'ubi'
|
cmd = 'python ' + extensions_path + 'NeoBoot/ubi_reader/ubi_extract_files.py rootfs.bin -o ' + getNeoLocation() + 'ubi'
|
||||||
@@ -1406,6 +1409,10 @@ def NEOBootExtract(source, target, ZipDelete):
|
|||||||
os.system('echo "Please wait. System installation multibox..."')
|
os.system('echo "Please wait. System installation multibox..."')
|
||||||
cmd = 'chmod 777 ' + getNeoLocation() + 'ImagesUpload/multibox; tar -jxf ' + getNeoLocation() + 'ImagesUpload/multibox/rootfs.tar.bz2 -C ' + getNeoLocation() + 'ImageBoot/' + target + ' > /dev/null 2>&1'
|
cmd = 'chmod 777 ' + getNeoLocation() + 'ImagesUpload/multibox; tar -jxf ' + getNeoLocation() + 'ImagesUpload/multibox/rootfs.tar.bz2 -C ' + getNeoLocation() + 'ImageBoot/' + target + ' > /dev/null 2>&1'
|
||||||
rc = os.system(cmd)
|
rc = os.system(cmd)
|
||||||
|
elif os.path.exists('' + getNeoLocation() + 'ImagesUpload/bre2ze4k'):
|
||||||
|
os.system('echo "Please wait. System installation bre2ze4k..."')
|
||||||
|
cmd = 'chmod 777 ' + getNeoLocation() + 'ImagesUpload/bre2ze4k; tar -jxf ' + getNeoLocation() + 'ImagesUpload/bre2ze4k/rootfs.tar.bz2 -C ' + getNeoLocation() + 'ImageBoot/' + target + ' > /dev/null 2>&1'
|
||||||
|
rc = os.system(cmd)
|
||||||
elif os.path.exists('' + getNeoLocation() + 'ImagesUpload/' + source + '.tar.xz'):
|
elif os.path.exists('' + getNeoLocation() + 'ImagesUpload/' + source + '.tar.xz'):
|
||||||
os.system('echo "Please wait. System installation spakowanego w plik tar.xz w toku..."')
|
os.system('echo "Please wait. System installation spakowanego w plik tar.xz w toku..."')
|
||||||
os.system('cp -af ' + getNeoLocation() + 'ImagesUpload/' + source + '.tar.xz ' + getNeoLocation() + 'ImagesUpload/rootfs.tar.xz')
|
os.system('cp -af ' + getNeoLocation() + 'ImagesUpload/' + source + '.tar.xz ' + getNeoLocation() + 'ImagesUpload/rootfs.tar.xz')
|
||||||
@@ -1430,7 +1437,7 @@ def NEOBootExtract(source, target, ZipDelete):
|
|||||||
os.chdir('ImagesUpload')
|
os.chdir('ImagesUpload')
|
||||||
os.system('mv -f rootfs.bin rootfs.bin')
|
os.system('mv -f rootfs.bin rootfs.bin')
|
||||||
os.system('echo "Instalacja - ubi_reader w toku..."')
|
os.system('echo "Instalacja - ubi_reader w toku..."')
|
||||||
print '[NeoBoot] Extracting UBIFS image and moving extracted image to our target'
|
print ("[NeoBoot] Extracting UBIFS image and moving extracted image to our target")
|
||||||
cmd = 'chmod 777 ' + extensions_path + 'NeoBoot/ubi_reader/ubi_extract_files.py'
|
cmd = 'chmod 777 ' + extensions_path + 'NeoBoot/ubi_reader/ubi_extract_files.py'
|
||||||
rc = os.system(cmd)
|
rc = os.system(cmd)
|
||||||
cmd = 'python ' + extensions_path + 'NeoBoot/ubi_reader/ubi_extract_files.py rootfs.bin -o ' + getNeoLocation() + 'ubi'
|
cmd = 'python ' + extensions_path + 'NeoBoot/ubi_reader/ubi_extract_files.py rootfs.bin -o ' + getNeoLocation() + 'ubi'
|
||||||
|
|||||||
@@ -56,8 +56,8 @@ else:
|
|||||||
from Screens.Console import Console
|
from Screens.Console import Console
|
||||||
|
|
||||||
loggscrash = time.localtime(time.time())
|
loggscrash = time.localtime(time.time())
|
||||||
PLUGINVERSION = '9.16'
|
PLUGINVERSION = '9.17'
|
||||||
UPDATEVERSION = '9.16'
|
UPDATEVERSION = '9.17'
|
||||||
UPDATEDATE = '"+%Y04%d"'
|
UPDATEDATE = '"+%Y04%d"'
|
||||||
LinkNeoBoot = '/usr/lib/enigma2/python/Plugins/Extensions/NeoBoot'
|
LinkNeoBoot = '/usr/lib/enigma2/python/Plugins/Extensions/NeoBoot'
|
||||||
|
|
||||||
@@ -925,8 +925,8 @@ class NeoBootImageChoose(Screen):
|
|||||||
if checkInternet():
|
if checkInternet():
|
||||||
pass
|
pass
|
||||||
else:
|
else:
|
||||||
self.session.open(MessageBox, _('Geen internet'), MessageBox.TYPE_INFO, 5)
|
mess = _('Geen internet')
|
||||||
self.close()
|
self.session.open(MessageBox, mess, MessageBox.TYPE_INFO)
|
||||||
|
|
||||||
if not fileExists('/.multinfo'):
|
if not fileExists('/.multinfo'):
|
||||||
out = open('%sImageBoot/.neonextboot' % getNeoLocation(), 'w' )
|
out = open('%sImageBoot/.neonextboot' % getNeoLocation(), 'w' )
|
||||||
@@ -1560,7 +1560,6 @@ class NeoBootImageChoose(Screen):
|
|||||||
mess = _('Sorry cannot open run file - Access Fails with Error code 0x40.')
|
mess = _('Sorry cannot open run file - Access Fails with Error code 0x40.')
|
||||||
self.session.open(MessageBox, mess, MessageBox.TYPE_INFO)
|
self.session.open(MessageBox, mess, MessageBox.TYPE_INFO)
|
||||||
|
|
||||||
|
|
||||||
def StartReboot(self, yesno):
|
def StartReboot(self, yesno):
|
||||||
if yesno:
|
if yesno:
|
||||||
try:
|
try:
|
||||||
@@ -1595,7 +1594,7 @@ def readline(filename, iferror = ''):
|
|||||||
|
|
||||||
def checkInternet():
|
def checkInternet():
|
||||||
if fileExists('/usr/lib/python3.8'):
|
if fileExists('/usr/lib/python3.8'):
|
||||||
pass
|
return True
|
||||||
else:
|
else:
|
||||||
import urllib2, urllib
|
import urllib2, urllib
|
||||||
try:
|
try:
|
||||||
@@ -1683,7 +1682,11 @@ def main(session, **kwargs):
|
|||||||
if mypath2 != 'Flash' or mypath2 == 'Flash' and checkimage():
|
if mypath2 != 'Flash' or mypath2 == 'Flash' and checkimage():
|
||||||
|
|
||||||
if fileExists('/.multinfo'):
|
if fileExists('/.multinfo'):
|
||||||
|
try:
|
||||||
session.open(NeoBootImageChoose)
|
session.open(NeoBootImageChoose)
|
||||||
|
except:
|
||||||
|
from Plugins.Extensions.NeoReboot.plugin import ForceReboot
|
||||||
|
session.open(ForceReboot)
|
||||||
else:
|
else:
|
||||||
if float(PLUGINVERSION) != version:
|
if float(PLUGINVERSION) != version:
|
||||||
try:
|
try:
|
||||||
|
|||||||
@@ -257,7 +257,7 @@ class InstallImage(Screen, ConfigListScreen):
|
|||||||
str(self.PiconR.value),
|
str(self.PiconR.value),
|
||||||
str(self.Kodi.value),
|
str(self.Kodi.value),
|
||||||
str(self.BlackHole.value))
|
str(self.BlackHole.value))
|
||||||
print '[NEO-BOOT]: ', cmd
|
print ("[MULTI-BOOT]: "), cmd
|
||||||
from Plugins.Extensions.NeoBoot.plugin import PLUGINVERSION
|
from Plugins.Extensions.NeoBoot.plugin import PLUGINVERSION
|
||||||
self.session.open(Console, _('NeoBoot v.%s - Install new image') % PLUGINVERSION, [message, cmd])
|
self.session.open(Console, _('NeoBoot v.%s - Install new image') % PLUGINVERSION, [message, cmd])
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user