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*

2
  • (1) You might want to parenthesize the groups, for clarity, as I did in Change all folder permissions with one command.  (2) See also my answer here (“the find command line is, effectively, an executable statement in an arcane language.”) to see, in general, why actions should always be placed after tests (it’s not specific to -delete). Commented Aug 27, 2024 at 21:18
  • Very helpful @G-ManSays'ReinstateMonica'! I wish the find command was a bit clearer on how they parse stuff prior to executing - I think it would clear up some of these syntax/semantic errors. I'm in the middle of writing a basic bash script to archive & cleanup logs upon application restarts and find is a much safer way to remove files than the rm command. Using tips like yours - I'm able to drastically simplify & clarify the code! Commented Aug 28, 2024 at 13:12