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:
Makes any files in the current directory (and any sub-directories) group-readable.
Using the "! -perm /g=r" limits the number of files to only those that do not already have this property
Using "+" on the end of the -exec body tells find to build the entire command by appending all matching files before execution, so invokes chmod once only, not once per file.
There are 3 alternatives - vote for the best!
If you can do better, submit your command here.
You must be signed in to comment.