With args: '--exclude=dir1' works fine, dir1 is excluded. How to exclude multiple directories? I tried
args: '--exclude=dir1 --exclude=dir2'
args: '--exclude={dir1,dir2}'
exclude: [dir1, dir2]
exclude: ['dir1', 'dir2']
with no luck. Rsync doesn't exclude anything with these setups.
Well, finally I figured out that it can be done like this:
args: '--exclude-from=list-of-files-to-exclude'
where list-of-files-to-exclude is file where all directories and files to be excluded are listed:
With
args: '--exclude=dir1'works fine,dir1is excluded. How to exclude multiple directories? I triedwith no luck.
Rsyncdoesn't exclude anything with these setups.Well, finally I figured out that it can be done like this:
where
list-of-files-to-excludeis file where all directories and files to be excluded are listed: