Chmod recursively directories and files
This will recursively search your directory tree (starting at dir 'dot') and chmod 777 all directories only.
find . -type d -exec chmod 777 {} \;
Similarly, the following will chmod all files only (and ignore the directories).
find . -type f -exec chmod 666 {} \;
Credit goes here.
Nick
5 Mar, 2012
Why you just can’t use chmod ./ -R 777 ?