How about:
find . -type f -name '*.dat' -delete

-type f will make sure you don't delete directories.

Bill

On 2/12/2017 2:43 PM, Stephen Morris wrote:
On 11/02/2017 22:24, bruce wrote:
Hi.

Test file with a name of:

67.205.168.80_PID.dat

find . -name '*.dat' -exec ls {} \;
displays the file

but
find . -name '*.dat' -exec rm -f {} \;
doesn't delete it.

thoughts?
Just a thought, does the delete fail because your userid doesn't have enough access to be able to delete them, hence you may have to do the delete through sudo?

regards,
Steve


thanks
_______________________________________________
users mailing list -- users@lists.fedoraproject.org
To unsubscribe send an email to users-le...@lists.fedoraproject.org
_______________________________________________
users mailing list -- users@lists.fedoraproject.org
To unsubscribe send an email to users-le...@lists.fedoraproject.org

_______________________________________________
users mailing list -- users@lists.fedoraproject.org
To unsubscribe send an email to users-le...@lists.fedoraproject.org

Reply via email to