find . -type f -exec chmod 644 {} + -o -type d -exec chmod 755 {} +
The '+' can replace the escaped ';' to tell the find exec to collect all the files first, and then execute (think xargs). And the '-o' will be short-circuited, so it will only test for a type of 'd' if the type is not 'f'.
No comments:
Post a Comment