Files
NeoBoot-9/iNB.sh

72 lines
2.8 KiB
Bash
Raw Normal View History

2020-01-07 11:38:42 +02:00
#!/bin/sh
#
2020-01-12 14:21:16 +02:00
#skrypt installs neoboot-a
2020-01-07 11:38:42 +02:00
#
if `grep -q 'osd.language=pl_PL' </etc/enigma2/settings`; then
PL=1
fi
2020-01-12 23:30:20 +02:00
if [ -e /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/files/mountpoint.sh ]; then
rm -f /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/files/mountpoint.sh;
rm -f /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/files/neom;
rm -f /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/files/neo.sh;
rm -f /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location
2020-01-18 08:00:56 +02:00
rm -f /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/bin/install
rm -f /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/bin/reading_blkid
2020-01-12 23:30:20 +02:00
fi
2020-01-18 08:18:26 +02:00
if [ -e /etc/fstab.org ]; then
rm -r /etc/fstab; mv /etc/fstab.org /etc/fstab
fi
if [ -e /etc/init.d/volatile-media.sh.org ]; then
mv /etc/init.d/volatile-media.sh.org /etc/init.d/volatile-media.sh; rm -r /etc/init.d/volatile-media.sh.org; chmod 755 /etc/init.d/volatile-media.sh
fi
2020-01-07 11:38:42 +02:00
[ -e /tmp/neoboot.zip ] && rm -f /tmp/neoboot.zip
2020-01-07 12:01:20 +02:00
[ -e /tmp/neoboot-master ] && rm -rf /tmp/neoboot-master
2020-01-07 11:38:42 +02:00
[ $PL ] && echo "Pobieranie archiwum..." || echo "Downloading archive file..."
2020-05-11 12:57:13 +03:00
URL='https://github.com/gutosie/NeoBoot-9/archive/master.zip'
2020-01-07 11:38:42 +02:00
curl -kLs $URL -o /tmp/neoboot.zip
cd /tmp/
if [ ! -e /tmp/master.zip ]; then
wget $URL
mv -f /tmp/master.zip /tmp/neoboot.zip
fi
unzip -qn ./neoboot.zip
rm -f /tmp/neoboot.zip
#kopiowanie
[ $PL ] && echo "Instalowanie..." || echo "Instaling..."
Cel="/usr/lib/enigma2/python/Plugins/Extensions"
[ -e $Cel/NeoBoot ] && rm -rf $Cel/NeoBoot/* || mkdir -p $Cel/NeoBoot
2020-05-11 12:57:13 +03:00
mv -f /tmp/NeoBoot-9-master/NeoBoot/* $Cel/NeoBoot
[ -e /tmp/NeoBoot8-master ] && rm -rf /tmp/NeoBoot-9-master
2020-01-07 11:38:42 +02:00
cd $Cel/NeoBoot
chmod 755 ./bin/*
chmod 755 ./ex_init.py
chmod 755 ./files/*.sh
2020-01-10 21:13:50 +02:00
chmod 755 ./files/neo_location
2020-01-07 11:38:42 +02:00
chmod -R +x ./ubi_reader/*
if [ $PL ] ; then
echo ""
echo "#####################################################"
2020-05-11 12:57:13 +03:00
echo "# NEOBOOT ZOSTAL ZAINSTALOWANY #"
2020-01-07 11:38:42 +02:00
echo "#####################################################"
2020-05-11 12:57:13 +03:00
echo "# ZRESTARTUJ TUNER #"
2020-01-07 11:38:42 +02:00
echo "#####################################################"
echo ""
else
echo ""
echo "#####################################################"
2020-01-10 10:04:20 +02:00
echo "# NEOBOOT INSTALLED SUCCESSFULLY #"
2020-01-07 11:38:42 +02:00
echo "#####################################################"
echo "# PLEASE RESTART YOUR STB #"
echo "#####################################################"
echo ""
fi
2020-01-07 12:01:20 +02:00
exit 0
echo "#####################################################"
echo "# NEOBOOT INSTALLED SUCCESSFULLY #"
echo "#####################################################"
echo "# PLEASE RESTART YOUR STB #"
echo "#####################################################"
echo ""
fi
2020-01-07 11:38:42 +02:00
exit 0