Re: delete directories with find and exclude other directories

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



On 02/03/2016 10:51 AM, m.roth@xxxxxxxxx wrote:
Right, but a) I think I tried using prune 20 years ago... and b) I thought
the o/p wanted to not deal with any directory whose name was logs. leaving
off prune would get everything, which is perhaps a bit more useful.

I think you don't understand. I was pointing out that the command you specified would print the name '.' and that is all. It won't descend through '.' because you told it to prune all directories not named "logs". That is, I'm trying to point out that it's your *logic* that's flawed.

OP was right in his thinking. The correct way to approach the problem is to ignore (prune) the logs dir, and then to do something with the remaining directories.
_______________________________________________
CentOS mailing list
CentOS@xxxxxxxxxx
https://lists.centos.org/mailman/listinfo/centos



[Index of Archives]     [CentOS]     [CentOS Announce]     [CentOS Development]     [CentOS ARM Devel]     [CentOS Docs]     [CentOS Virtualization]     [Carrier Grade Linux]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Linux USB]
  Powered by Linux