Delete multiple files with wildcard

14 views
Skip to first unread message

PiBorg

unread,
Dec 26, 2018, 3:19:56 AM12/26/18
to Tasker
Hi

I want to delete several files with the extension .lnk from the folder files. In Tasker there is only the menu item File -> Delete File. Using the menu it is not possible to delete multiple files with the wildcard *.lnk.

So how can I delete several files in one go?

Thanks for your help

Rich D

unread,
Dec 26, 2018, 4:54:36 AM12/26/18
to Tasker Google Groups Post


I want to delete several files with the extension .lnk from the folder files.  In Tasker there is only the menu item File -> Delete File.  Using the menu it is not possible to delete multiple files with the wildcard *.lnk.

So how can I delete several files in one go?

Not possible with tasker file actions. You might be able to do it with a action -> Code -> JavaScriptlet .  Just Google for some javascriptlet code.

To do it with tasker file actions you would need a for loop. You can get a filtered file list with the 'list files' action then delete them in a for loop. 

Sla Z3

unread,
Dec 26, 2018, 2:35:23 PM12/26/18
to tas...@googlegroups.com
Thank you so much for your feedback.  For a beginner the way was too complicated for me.  I solved it with a Run Shell rm -f and the absolute path to the folder/*

Thanks again

Am Mi., 26. Dez. 2018, 10:54 hat Rich D <ricp...@gmail.com> geschrieben:
--
You received this message because you are subscribed to the Google Groups "Tasker" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tasker+un...@googlegroups.com.
Visit this group at https://groups.google.com/group/tasker.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages