Sunday, March 9, 2014

Find command


Recursive chmod only files within this folder:

find . -type f -exec chmod 0644 {} \;

Recursive chmod only folders within this folder:

find . -type d -exec chmod 0755 {} \;

into a bash script, so it could be something like:

For files:

rchmodf 744 .

For directories:

rchmodd 755 .

and... also maybe into a nautilus right click menu option if that's possibl