I am looking for syntax I saw somewhere but can not find now. Working with the results of a find delete the files found.
The syntax is something like this:
for i in "${find . -name '*.ini'}"; do rm $i; done
Am I dreaming or is this possible?
I am looking for syntax I saw somewhere but can not find now. Working with the results of a find delete the files found.
The syntax is something like this:
for i in "${find . -name '*.ini'}"; do rm $i; done
Am I dreaming or is this possible?
Instead of using for loop you can delete files by using
find . -name '*.ini' -exec rm '{}' \;
Thanks ravi89. It'll do the trick. :)
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.