View Single Post
Posts: 108 | Thanked: 44 times | Joined on Nov 2009 @ Como, Italy
#23
haven't tried but this should work :P

#!/bin/sh -e
trap exit SIGHUP SIGINT SIGTERM
PATH=/bin:/usr/bin:/sbin:/usr/sbin

if [ -x /mnt/initfs/usr/bin/cal-tool ]; then
CALTOOL="/usr/sbin/chroot /mnt/initfs cal-tool"
else
CALTOOL="cal-tool"
fi

MODE=`$CALTOOL --get-rd-mode`
if [ x$MODE = xenabled ]
then
echo "Root shell enabled"
/bin/sh
else
echo "Enable RD mode if you want to break your device"
fi
__________________
computer 1st, phone 2nd