mirror of
https://github.com/gutosie/neoboot.git
synced 2025-11-01 11:55:47 +01:00
Update userscript.sh
This commit is contained in:
@@ -2,63 +2,77 @@
|
|||||||
# script gutosie
|
# script gutosie
|
||||||
# here you can add your own command to perform
|
# here you can add your own command to perform
|
||||||
# line - Checking internet connection by @j00zek thank you
|
# line - Checking internet connection by @j00zek thank you
|
||||||
if [ -f /.control_boot_new_image ] ; then
|
|
||||||
passwd -d root
|
if [ ! -f /etc/rc.local ] || [ ! -f /etc/init.d/rc.local ] || [ ! -f /etc/init.d/rcS.local ]; then
|
||||||
ln -sf "/usr/lib/enigma2/python/Plugins/Extensions/NeoBoot" "/NeoBoot"
|
echo "...rc.local does not exist..."
|
||||||
fi
|
elif [ -f /etc/rc.local ] || [ -f /etc/init.d/rc.local ] || [ -f /etc/init.d/rcS.local ]; then
|
||||||
if [ ! -f `cat /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location`ImageBoot/.neonextboot ] ; then
|
if [ -f /etc/rcS.d/S99neo.local ] ; then
|
||||||
mkdir `cat /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location`
|
rm -f /etc/rcS.d/S99neo.local
|
||||||
/usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/files/neo.sh
|
echo "...rm S99neo.local..."
|
||||||
echo "...Start -neo.sh- mount point location NEOBOOT..."
|
else
|
||||||
fi
|
echo "...rc.local exist..."
|
||||||
if [ ! -e /usr/bin/enigma2_pre_start.sh ]; then
|
break ;
|
||||||
/usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/files/mountpoint.sh
|
fi
|
||||||
echo "...Start -mountpoint.sh- location NEOBOOT..."
|
|
||||||
fi
|
|
||||||
if [ -f /.control_boot_new_image ] ; then
|
|
||||||
break ;
|
|
||||||
else
|
else
|
||||||
#if [ -f /usr/lib/python2.7 ] ; then
|
|
||||||
echo "....................-NEOBOOT-...................."
|
if [ -f /.control_boot_new_image ] ; then
|
||||||
echo "...Checking internet connection..."
|
passwd -d root
|
||||||
ping -c 1 github.com 1>/dev/null 2>%1
|
ln -sf "/usr/lib/enigma2/python/Plugins/Extensions/NeoBoot" "/NeoBoot"
|
||||||
if [ $? -gt 0 ]; then
|
fi
|
||||||
echo "...github server unavailable..."
|
if [ ! -f `cat /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location`ImageBoot/.neonextboot ] ; then
|
||||||
echo "...The network has no connection..."
|
mkdir `cat /usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/.location`
|
||||||
echo "...Network RESTART..."
|
/usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/files/neo.sh
|
||||||
echo "...restart network connection..."
|
echo "...Start -neo.sh- mount point location NEOBOOT..."
|
||||||
/etc/init.d/vuplus-wifi-init.sh
|
fi
|
||||||
#/etc/wpa_supplicant/action_wpa.sh
|
if [ ! -e /usr/bin/enigma2_pre_start.sh ]; then
|
||||||
#/etc/wpa_supplicant/functions.sh
|
/usr/lib/enigma2/python/Plugins/Extensions/NeoBoot/files/mountpoint.sh
|
||||||
#/etc/wpa_supplicant/ifupdown.sh
|
echo "...Start -mountpoint.sh- location NEOBOOT..."
|
||||||
#ifconfig sys0 up
|
fi
|
||||||
#/etc/udhcpc.d/50default restart
|
if [ -f /.control_boot_new_image ] ; then
|
||||||
/etc/init.d/networking restart
|
break ;
|
||||||
echo "...Restart network finish..."
|
else
|
||||||
echo ".............................."
|
#if [ -f /usr/lib/python2.7 ] ; then
|
||||||
sleep 1
|
echo "....................-NEOBOOT-...................."
|
||||||
else
|
echo "...Checking internet connection..."
|
||||||
echo "...github server available..."
|
ping -c 1 github.com 1>/dev/null 2>%1
|
||||||
echo "...The network has a connection. It is OK..."
|
if [ $? -gt 0 ]; then
|
||||||
fi
|
echo "...github server unavailable..."
|
||||||
#else
|
echo "...The network has no connection..."
|
||||||
#break ;
|
echo "...Network RESTART..."
|
||||||
|
echo "...restart network connection..."
|
||||||
#fi
|
/etc/init.d/vuplus-wifi-init.sh
|
||||||
|
#/etc/wpa_supplicant/action_wpa.sh
|
||||||
|
#/etc/wpa_supplicant/functions.sh
|
||||||
|
/etc/wpa_supplicant/ifupdown.sh
|
||||||
|
#ifconfig sys0 up
|
||||||
|
#/etc/udhcpc.d/50default restart
|
||||||
|
/etc/init.d/networking restart
|
||||||
|
echo "...Restart network finish..."
|
||||||
|
echo ".............................."
|
||||||
|
sleep 1
|
||||||
|
else
|
||||||
|
echo "...github server available..."
|
||||||
|
echo "...The network has a connection. It is OK..."
|
||||||
|
fi
|
||||||
|
#else
|
||||||
|
#break ;
|
||||||
|
#fi
|
||||||
|
fi
|
||||||
|
if [ -f /zImage ] ; then
|
||||||
|
rm -r /zImage
|
||||||
|
fi
|
||||||
|
if [ -f /%1 ] ; then
|
||||||
|
rm -f /%1
|
||||||
|
fi
|
||||||
|
if [ -f /home/root/%1 ] ; then
|
||||||
|
rm -f /home/root/%1
|
||||||
|
fi
|
||||||
|
if [ -f /STARTUP ] ; then
|
||||||
|
rm -r /STARTU*
|
||||||
|
fi
|
||||||
|
echo "...NEOBOOT used user script Finish..."
|
||||||
|
echo "....................-NEOBOOT-...................."
|
||||||
|
echo "............................................"
|
||||||
fi
|
fi
|
||||||
if [ -f /zImage ] ; then
|
|
||||||
rm -r /zImage
|
|
||||||
fi
|
|
||||||
if [ -f /%1 ] ; then
|
|
||||||
rm -f /%1
|
|
||||||
fi
|
|
||||||
if [ -f /home/root/%1 ] ; then
|
|
||||||
rm -f /home/root/%1
|
|
||||||
fi
|
|
||||||
if [ -f /STARTUP ] ; then
|
|
||||||
rm -r /STARTU*
|
|
||||||
fi
|
|
||||||
echo "...NEOBOOT used user script Finish..."
|
|
||||||
echo "....................-NEOBOOT-...................."
|
|
||||||
echo "............................................"
|
|
||||||
exit 0
|
exit 0
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user