chmod operation on directories / files
Yi Wang
wangyi6854 at gmail.com
Wed May 7 14:39:27 UTC 2008
sorry, I forgot to reply to all.
for directorys, you can use:
chmod 755 */
if the files have a suffix. you can use
chmod 644 *.*
for the files don't have the suffix, I guess a regex should solve it.
But I'm not familiar with regex. :-)
On 5/7/08, Catalin Miclaus <catalin at starcomms.com> wrote:
> -----Original Message-----
> From: owner-freebsd-questions at freebsd.org
> [mailto:owner-freebsd-questions at freebsd.org] On Behalf Of Zbigniew
> Szalbot
> Sent: Wednesday, May 07, 2008 12:57 PM
> To: freebsd-questions at freebsd.org
> Subject: chmod operation on directories / files
>
> Hello,
>
> How do I chmod separately files and directories?
>
> If I use chmod -R 644 then it will go through all the subdirectories
> assigning everything 644 permissions, directories including.
>
> Many thanks!
>
> --
> Zbigniew Szalbot
> www.lc-words.com
>
>
>
>
>
> find /test -type f -exec chmod 644 {} \;
>
> Replace /test with full path to your directory.
> For directories use '-type d'.
>
>
>
>
> Best Regards
>
> Catalin Miclaus
> Network/Security ISP-Data
> Starcomms Ltd.
>
>
> _______________________________________________
> freebsd-questions at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to "freebsd-questions-unsubscribe at freebsd.org"
>
--
Regards,
Wang Yi
More information about the freebsd-questions
mailing list