View Single Post
Posts: 1,313 | Thanked: 2,978 times | Joined on Jun 2011 @ Finland
#969
Originally Posted by kai_en View Post
curious why enter sh -c, shouldn't "rm /home/user/.cache/data/twitter/twcache*" be sufficient?
No, because there is that "*". This is a wildcard, and it's evaluation needs a shell. So "sh -c" is used to run the command in the shell, which expands the "twcache*" into all the files that match the wildcard.

So in reality the command becomes something like:

Code:
rm /home/user/.cache/data/twitter/twcache.db /home/user/.cache/data/twitter/twcache.dat1 /home/user/.cache/data/twitter/twcache.dat2
I have for quite a while now thought that I should add to ProfileMatic an option (which would by default be on) to run the custom action in shell so that you don't need to add "sh -c". Most people assume custom action behaves like a shelll, and many people who use shell quite comfortably are not really aware of the shell expansion rules.

But this is something that I don't have time for a while.
__________________
My N9/N950 projects:
 

The Following User Says Thank You to ajalkane For This Useful Post: