How to exclude folder with rdiff-backup when not at beginning

0

1

I have an rdiff-backup I am trying to run and want to exclude all paths that contain 'Application Data/Slack/*'. My source path is /src and target is /dest. So I am trying to do:

rdiff-backup /src /dest

For a source tree looking like:

/src/dir1/a/b/file1.txt
/src/dir1/a/b/file2.txt
/src/dir2/Application Data/Slack/file1.txt    
/src/dir2/Application Data/Slack/some folder/file2.txt
/src/dir3/dir4/file4.txt

I want this to be copied:

/src/dir1/a/b/file1.txt
/src/dir1/a/b/file2.txt
/src/dir3/dir4/file4.txt

I tried various combinations of:

rdiff-backup --exclude '**/Application Data/Slack/' /src /dest

but do not seem to get it to ignore those Slack directories. What am I doing wrong? This is entered straight in bash console. Latest version of all components I believe.

pwnell

Posted 2019-06-30T01:30:37.317

Reputation: 1

No answers