so it seems like there are others with the same problem, but I couldn't find the right solution for myself. What I want to do: Rsync all files with pattern .log. but exclude a directory
Here is my rsync command:
rsync --include=*/ --include=*.log.* --exclude=* --exclude=folder1/ -armte "ssh -o StrictHostKeyChecking=no" user@server:/path/log/ /tmp/rsynctest/
So in /path/log are multiple subfolders. /path/log/folder0 /path/log/folder1 /path/log/folder2 etc. And I want to exclude one of them (folder1). But rsync is still syncing this folder. I'm not really sure what I'm doing wrong.
/
at folder1. use only--exclude=folder1
– Rahul Sep 13 '16 at 06:24--exclude=folder1/
first. – Gilles 'SO- stop being evil' Sep 13 '16 at 06:44