#!/bin/sh -


. /etc/profile
export LANG=en_US.UTF-8
_p_file="${0%/*}/../../../var/mobile/Library/Preferences/com.nan.raru.conf"

if [ ! -f '/basebin/.safe_mode' ]; then
	if [ ! -f "${_p_file}" ]; then
		echo -n '10' >"${_p_file}"
	fi
	if ! sleep "$(cat "${_p_file}" | sed -n '1p')"; then
		sleep 10
		echo -n '10' >"${_p_file}"
	fi
	killall -9 dasd
	killall -9 cfprefsd
	if which sbreload 2>>/dev/null 1>>/dev/null; then
		sbreload
	else
		killall -9 backboardd
		killall -9 SpringBoard
	fi
fi
launchctl unload '/Library/LaunchDaemons/com.nan.raru.plist'
exit 0
