Hi my friends
I want a flow to check file size on this directory "/mnt/sdcard/a.txt" and when it larger than 17kb does an action.
Please help me...
check file size
Moderator: Martin
-
- Posts: 18
- Joined: 13 Sep 2013 03:11
Re: check file size
It does not appear to be supported. I tried to do eval ("ls /sdcard") but it looks like only AA functions can be eval'd.
There aren't any actions for file size either.
I don't recall seeing that in the list for 1.19 either.
I didn't even find a way to do this with Tasker. I know it can be done with ruboto but that is a little more involved.
There aren't any actions for file size either.
I don't recall seeing that in the list for 1.19 either.
I didn't even find a way to do this with Tasker. I know it can be done with ruboto but that is a little more involved.
Re: check file size
Hi,
You can try to execute a shell command like Execute Command: ls -l /mnt/sdcard/a.txt or Execute Command: du /mnt/sdcard/a.txt and then use variable stdout.
The variable will most likely not just contain the size but also the file name so you have to use a script to extract the substring containing the size.
Regards,
Martin
You can try to execute a shell command like Execute Command: ls -l /mnt/sdcard/a.txt or Execute Command: du /mnt/sdcard/a.txt and then use variable stdout.
The variable will most likely not just contain the size but also the file name so you have to use a script to extract the substring containing the size.
Regards,
Martin