SHARE
TWEET

Xperia acro HD (IS12S) init.clrdex.sh (6.1.D.0.170)

huhka_com Jul 31st, 2012 95 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #!/system/bin/sh
  2. #
  3. # Copyright 2012 Sony Ericsson Mobile Communications AB.
  4. # Copyright (C) 2012 Sony Mobile Communications AB.
  5. # All rights, including trade secret rights, reserved.
  6. #
  7. # Delete all files in the dalvik-cache to make sure there is enough
  8. # space on the data partition when doing an upgrade.
  9. # The dalvik-cache is only cleared if the $MARK file is not present.
  10. # The name of the MARK file should be changed for each upgrade.
  11. #
  12. TAG="clrdex"
  13. DST="/data/dalvik-cache"
  14. #
  15. # The MARK variable is the name of a file which if present disables clean
  16. # up of dex files.
  17. #
  18. MARK="clear-done-ics"
  19.  
  20. check_file_exists()
  21. {
  22.   /system/bin/log -t $TAG -p i "Checking $1 ..."
  23.   if `/system/bin/ls $1 > /dev/null`; then
  24.     return 0
  25.   else
  26.     return 1
  27.   fi
  28. }
  29.  
  30. if ! check_file_exists $DST/$MARK ; then
  31.   /system/bin/log -t $TAG -p i "Clearing dalvik cache ..."
  32.   /system/bin/rm  $DST/*
  33.   /system/bin/touch $DST/$MARK
  34.   /system/bin/chmod 0644 $DST/$MARK
  35. fi
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top