Re: exclude error "cannot match" but dir exists
Mike Fleetwood via Any discussion of rdiff-backup <[email protected]>
| Newsgroups | gmane.comp.sysutils.backup.rdiff-backup.general |
|---|---|
| Message-ID | <CAMU1PDhaGy6q5GQQuDv5DAb3aFUD+dc+ZktoJ+__G8cAKrGHNA@mail.gmail.com> |
On Wed, 13 May 2020 at 15:42, RL <[email protected]> wrote: > > rufus@Air-PC:~/WK/testin> rdiff-backup -v3 --include > /home/rufus/WK/testin/dummy --exclude ** /home/rufus/WK/testin > /home/rufus/WK/testout2 > Fatal Error: Switches missing or wrong number of arguments > See the rdiff-backup manual page for more information. > rufus@Air-PC:~/WK/testin> > > And how is "--exclude **" (last example fail) wrong? Switches? Arguments? > The shell will be expanding ** to all the files in the current directory. To see what is actually passed to the command run: echo MYCOMMANDLINE To prevent the shell performing file name pattern matching expansion, enclose that parameter in single quotes thus '**'. I suggest you read the EXPANSION section and Pattern Matching sub-section of the bash manual. man bash Mike