[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: chmod directory mode extention
From: |
Eric Blake |
Subject: |
Re: chmod directory mode extention |
Date: |
Sat, 20 Feb 2010 17:51:39 -0700 |
User-agent: |
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.23) Gecko/20090812 Thunderbird/2.0.0.23 Mnenhy/0.7.6.666 |
According to seaking1 on 2/20/2010 5:26 PM:
> I would like to suggest and offer the code to extend chmod in a small
> way. My extension merely allows for a different mode to be applied to
> directories than the one applied to all other files.
Thanks for the report. However, it is difficult to justify adding new
features when, to some extent, such an option already exists.
> With this is could run chmod -R -d 775 644 foo/
> and give the directories the permissions 775.
Rather than using numeric permissions, you can use symbolic permissions.
For example, this usage is guaranteed by POSIX to grant directory search
permissions and to preserve file executable permissions where they already
existed, without granting it to non-executable files.
chmod -R ug+X,o-x foo/
--
Don't work too hard, make some time for fun as well!
Eric Blake address@hidden
signature.asc
Description: OpenPGP digital signature