Re: remove/delete files with dots "." in the name..

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 11 February 2017 at 14:24, bruce <badouglas@xxxxxxxxx> 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?
>

I am not sure this is the problem, but I always enclose braces with
single quotes '{}' .

>From the man page:
       find . -type f -exec file '{}' \;

       Runs `file' on every file in or below the current directory.
Notice that the braces are enclosed in single quote marks to protect
them from interpretation as shell script punctuation. The semicolon is
similarly protected by the use of a backslash, though single quotes
could have been used in that case also.

-- 
Ahmad Samir
_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux