Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

3
  • One way to nest -execs is to use a shell as in -exec sh -c 'for file do find "$file" -exec cmd \{\} +; done' sh {} + Commented Sep 18, 2019 at 6:13
  • 1
    And the -prune problem can then be addessed with find "$file/." ! -name . -prune... Commented Sep 18, 2019 at 6:14
  • @StéphaneChazelas Sure but for this particular example, if you're going to use a shell, you don't need a nested find invocation at all. I was discussing a find-without-sh solution. Commented Sep 18, 2019 at 6:31