Hi,
I have a rooted phone (Samsung Note 2), Tasker and Secure Settings.
One of my task actions backs up some files in the middle of the night via FolderSync, but since the amount of files in the backup folders constantly increases (e. g. the WhatsApp database files) I have to go to the folders myself on a regular basis to delete the older stuff manually.
I've been searching for ages, but there doesn't seem to be a way to tell Tasker to delete files in a certain folder after a certain time (3 days or so) based on their creation date. Sadly I have no experience at all with scripts, but looked around and tried to copy/adjust one with the following text:
@! find /storage/sdcard0/WhatsApp/Databases/* -mtime +3 -exec rm -rf {} \;
(
Source)
After backing up the folder I tried running the script in a Tasker action via Secure Settings --> Run Command, but it's not working.
Any idea if this would/should actually do what I'm trying to accomplish and how to set it up in Tasker?
Thank you very much in advance!
Scolaro