exclude hidden files

Robert Parker rlp1938 at gmail.com
Fri Aug 19 05:03:58 MDT 2011


On Fri, Aug 19, 2011 at 5:47 PM, Ken Gillett <emailist at ukgb.net> wrote:
> I want to exclude from the sync ALL files that start with a dot, IOW hidden files. But using --exclude '.*' does funny things with directories (or at least I think it does). Is there a recognised correct way to do this?
>
> I thought --exclude '.???*' would avoid the directory issue by only excluding any dot file(dir) with a name longer than 2 characters. Not tried it yet, but would this be a good solution?


I think you need to specifically name the dot files you want to
exclude, eg '.*.swp' will ignore vi/vim swap files.

Bob Parker

>
>
>
> Ken  G i l l e t t
>
> _/_/_/_/_/_/_/_/
>
>
>
>
> --
> Please use reply-all for most replies to avoid omitting the mailing list.
> To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
> Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html
>



-- 
Scientific studies prove that scientists are whores just like the rest
of us wage slaves.


More information about the rsync mailing list