From 10373192c225aad62e3d5dd3a8019e5b813ab1e5 Mon Sep 17 00:00:00 2001 From: Tommy Sparber Date: Sun, 26 Jan 2014 16:58:15 +0100 Subject: [PATCH] Adding option to clear uicache on install --- bin/iosod | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/bin/iosod b/bin/iosod index f851f6e..7c18cfe 100755 --- a/bin/iosod +++ b/bin/iosod @@ -205,7 +205,7 @@ export Action_RunFuncOnDevice=("func" "[-h host_address] [-p host_port] function or, if that variable does not exist, the default SSH port 22 is used. Available functions: - respring, reboot") + respring, reboot, uicache") export Action_XcodeBuildPhaseLogos=("--xcbp-logos" "" "" 0 0 xcodeBuildPhase_Logos false \ " DO NOT USE. For use by Xcode as a Build Phase for projects created from @@ -1468,6 +1468,9 @@ function runFuncOnDevice() # args: function, hostAddress, hostPort respring) cmd="killall SpringBoard" ;; + uicache) + cmd="su mobile -c uicache" + ;; *) panic $? "Invalid function: $func" ;; @@ -1779,6 +1782,12 @@ function xcodeBuildPhase() # no args # install package on device # managePackageOnDevice "install" "$allPackagesDir/$packageFileName" "$iOSOpenDevDevice" "$iOSOpenDevPort" + # clear uicache? # + if [[ "$iOSOpenDevClearUiCacheOnInstall" == "YES" ]]; then + echo "Clearing uicache device..." + runFuncOnDevice "uicache" "$iOSOpenDevDevice" + fi + # respring? # if [[ "$iOSOpenDevRespringOnInstall" == "YES" ]]; then echo "Respringing device..."