Since GNOME settings are generally stored via the GSettings API, and some of those files are binaries/databases, your best bet is to rely on
To export settings:
dconf dump / > dconf-settings.ini
To import settings:
dconf load / < dconf-settings.ini
You could save the contents of
$XDG_CONFIG_HOME/dconf(most of the time, it represents
~/.config/dconf) but that would not be suitable for
git since those files are not plaintext.
This Gnome Settings export will also contain all settings related to Mate Desktop and Cinnamon Desktop since they are objects inside the root schema (
/ ). To export those desktops settings only:
dconf dump /org/cinnamon/ > dconf-cinnamon.ini
dconf dump /org/mate > dconf-mate.ini
Backup custom themes.
To backup your custom themes/icons, compressing the folders
~/.themes should be enough. Maybe you should keep the original theme files you already have at your home dir...