My use case is simple enough; to backup home dir without hidden files and without some other dirs, e.g. Downloads. But to also including a few of the hidden files.
One example of the hidden files is the firefox bookmarks directory.
So, the config includes "- .*" at the end of the list and has "+ .mozilla/firefox/xxxxxxxx.default-release/bookmarkbackups/*"
or hopefully more generically "+ .mozilla/firefox/*.default*/bookmarkbackups/*". The problem with the firefox files backup is that none of the bookmark files are backed up, nor anything else in the .mozilla directory which is the intent.
The current rsyncFiles.cfg file is show below. The logic is to exclude what I dont want, so that all else is backed up, achieved with the last line "- .*". This more recent approach to find a solution to the issue may well cause most of the lines beginning with "- " to not be needed. Anyway, thus far ... .
Tried dozens of suggestions from google searches to no avail. Please help!
The rsync command being used is:
Code:
rsync -navhsHm --exclude-from=$HOME/.rsync-backup/rsyncFiles.cfg ~/ /media/backup/$HOME/
and the current "rsyncFiles.cfg" file contains:
Code:
#Directories
- /snap
- /deja-dup
- /Downloads
- /Public
- /Videos
- /dwhelper
- /efax-gtk-server
- /faxin
- /faxout
- /faxsent
- /my_docker
#Mounted filesystem
- .local/share/gvfs-metadata
- .Private
- .gvfs
#Session-specific directories and files
- .dbus
- .cache
- .Trash
- .local
- .Xauthority
- .ICEauthority
- .pulse-cookie
- .var
- .config
- .gconf
- .gnome2_private
- *.parts
+ .ssh
+ .cert
+ .bash*
+ .profile
#Recent Files
- ./local/share/recently-used.xbel
#Firefox
+ .mozilla/*
+ .mozilla/firefox/*
+ .mozilla/firefox/*.default-*/*
+ .mozilla/firefox/*.default*/bookmarkbackups/*
- .mozilla/***
#Other Applications
+ .thunderbird
- .*
Bookmarks