find . -type d -print0 | xargs -0 chmod 755 find . -type f -print0 | xargs -0 chmod 644 or find . -type d -exec chmod 0755 {} ; find . -type f -exec chmod 0644 {} ;