su
Diff
code posted
created at 27 Oct 13:21
Edit
|
Back
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
su sqlite3 /data/data/com.android.providers.media/databases/external.db "select _data from files;" | grep "mp3" > /sdcard/log.txt num_strings=`wc -l /sdcard/log.txt` count=0 killall android.process.media killall sqlite3 while read p; do STAT=`stat -c%Y "$p"` p2="${p//\'/\'\'}" QUERY="update files set date_added='$STAT', date_modified='$STAT' where _data like '$p2'" echo "["$count"/"$num_strings"] $p" sqlite3 /data/data/com.android.providers.media/databases/external.db "$QUERY" count=$((count+1)) done < /sdcard/log.txt rm /sdcard/log.txt |
576 Bytes in 2 ms with coderay