Date: 23 Aug 1999 00:33:54 -0400 From: Kevin Street <street@iname.com> To: "Rodney W. Grimes" <freebsd@gndrsh.dnsmgr.net> Cc: cvs-all@FreeBSD.ORG Subject: Re: cvs commit: src/etc/mtree README Message-ID: <87r9kv6rpp.fsf@mired.eh.local> In-Reply-To: "Rodney W. Grimes"'s message of "Sun, 22 Aug 1999 18:38:02 -0700 (PDT)" References: <199908230138.SAA33709@gndrsh.dnsmgr.net>
next in thread | previous in thread | raw e-mail | index | archive | help
"Rodney W. Grimes" <freebsd@gndrsh.dnsmgr.net> writes: > e) Add missing and remove extra entries (producing this last one > is being a bit of a pain, anyone have a quick command to find > directories that have no entries in them?). This finds (and deletes) empty dirs. I'd recommend you change the rmdir in the middle to something more suitable for your purposes... find -d . -type d | perl -lne \ 'opendir(D,$_);@f=readdir(D);rmdir if $#f == 1;closedir(D);' I don't remember who I stole this from. I think it was part of the predecessor of mergemaster. -- Kevin Street street@iname.com To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?87r9kv6rpp.fsf>