I am backing up data from a folder in MAC. The MAC unnecessarily creates some files startinmg with . like
.dsdfsd or ._hjdds
Now i want to exclude the files starting with . in rsync .
How can i do that
|
I am backing up data from a folder in MAC. The MAC unnecessarily creates some files startinmg with . like
Now i want to exclude the files starting with . in rsync . How can i do that |
|||
|
|
|
If you search in the rsync man page for "exclude", you will find:
So this would probably work:
|
|||||
|
|
I would replace Dennis's regex with
The ".*" pattern got me into a lot of trouble way back in my youth, when I tried to remove all of the hidden files from someone's home directory...
Is NOT a good thing to do. (Here's a hint: .* matches ..) [EDIT] Thanks to Dennis commenting on this, you can disregard my warning (though I'm leaving the comment to show that I'm doubly an idiot) ;-) |
|||||||
|