How to rsync and exclude hidden files?

Brian Cluff brian at snaptek.com
Thu Apr 29 17:30:04 MST 2010


You should be able to use this command:

rsync -avH --progress --exclude '.*' /home/joe/ \
	joe at 192.168.0.73:/home/joe

Also try adding the -n or --dry-run flag before running your rsync show 
what it's going to do without actually doing it, so that you can make 
sure it's going to do what you think it going to do before it actually 
does it.

Brian Cluff

On 04/29/2010 04:12 PM, joe at actionline.com wrote:
>
> Thanks to the always excellent help and advice from my plug friends,
> I've been able to use 'rsync' to copy files between my Linux boxes,
> and it has been a tremendous help.
>
> However, from studying the man page, I can't figure out what the
> syntax should be to exclude hidden files. When I use this:
>
> rsync -avH --progress /home/joe/ joe at 192.168.0.73:/home/joe/
>
> It copied all the hidden files and kind of messed up my laptop.
>
> How can I modify that command to exclude hidden files?
>
>
>
>
> ---------------------------------------------------
> PLUG-discuss mailing list - PLUG-discuss at lists.plug.phoenix.az.us
> To subscribe, unsubscribe, or to change your mail settings:
> http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss
>



More information about the PLUG-discuss mailing list