commandlinefu.com is the place to record those command-line gems that you return to again and again.
You can sign-in using OpenID credentials, or register a traditional username and password.
Subscribe to the feed for:
forces user to rw, group to r, and other to no access.
files will not be marked executable.
directories will be executable for users and groups only.
There are 3 alternatives - vote for the best!
With GNU chmod at least it is that simple.
Useful if you have copied files from an OS without a permission structure (for example, DOS) and you need to disable all executable files but want to be able to descend into your directories.
I hate -exec with find, and this pattern quickly expands to other tasks.
If you can do better, submit your command here.
You must be signed in to comment.