How to change file or folder permissions recursively with chmod

To set only files that end with .tpl to 600 (pattern escaped with slashes)

find . -name \*\.tpl -exec chmod 600 {} \;

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.