Like this:
find . -type d -exec chmod 755 {} \;or like this:
find . -type f -exec chmod 664 {} \;. is the path, the current directory in this example.
-type d - find directories only.
Similarly -type f would find files only.
{} gets replaced with the current found dir/file.
\; simply marks the end of the -exec part.
Source