[thelist] Freebie

Mike Migurski mike at saturn5.com
Thu Feb 13 04:17:01 CST 2003


>oh, and for those interested, i was lazy and didn't bother to code it to
>work in anything other than ie5+.
>
>http://members.evolt.org/jeff/code/chmod.cfm
>
>fwiw, it not only shows you what the directory listing will look like,
>but you can also type in your own 10 character permission string and
>it'll show you the associated chmod as well as check the appropriate
>checkboxes.

Just for everyone's benefit, there are two factors that make working with
chmod a whole lot easier than it seems from dealing with bitmasks:

1) there aren't that many oft-used combinations. For example, you'd rarely
set a file or directory to group or world accessible, but not user
accessible. You also would rarely set write or execute permissions on a
file you don't already have read permissions on. The smart people who
designed permissions made them work, therefore, in a consistently
left-to-right fashion (if you're looking at the "-rwxrwxrwx"
representation): more restrictive usually means more options on the left,
less restrictive usually means more on the right. You'd rarely see file or
directories where there's a right-side balance of permissions.

2) if you're using chmod on the command-line, feel free to do away with
the octal representation, because the utility provides a number of
shortcuts which make it easier to modify permissions. Instead of
digit-digit-digit, you can use the who-operator-permissions syntax, which
allows to do things like adding or removing specific permissions on a
directory-wide basis, or setting one's permissions to equal someone
else's. Useful for promoting or demoting members of your group in one
shot, for example. Check the man-page for more details.

---------------------------------------------------------------------
michal migurski- contact info and pgp key:
                 http://www.saturn5.com/mike/contact.html

                "Freedom! Horrible, horrible freedom!"






More information about the thelist mailing list