Problem with --exclude command

Paul Slootman paul+rsync at wurtel.net
Thu Nov 15 17:32:42 GMT 2007


On Thu 15 Nov 2007, alex loutrbringa' wrote:

> serv-dev:~/scripts_Admin# RSYNC_PASSWORD=xxxx /usr/bin/rsync -vv --checksum
> --recursive --links --exclude .svn/ --exclude test/ /var/www/ssl/
[...]
> [sender] excluding directory .svn because of pattern .svn/
> [sender] excluding directory test because of pattern test/
> [sender] excluding directory downloads/test because of pattern test/
[...]
> So downloads/test is excluded from the rsync but i just want my ./test/
> folder being excluded from the transfer, not my downloads/test/ folder.

Try --exclude /test/
The leading slash anchors it to the top of the transfer hierarchy.


Paul Slootman


More information about the rsync mailing list