Support restoring dconf.

This commit is contained in:
David Tomaschik
2018-07-08 13:56:37 -07:00
parent 8d9cf14608
commit da545f0de7
2 changed files with 35 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
[media-keys]
screensaver=['<Primary><Alt>l', 'XF86ScreenSaver']
[wm]
move-to-workspace-1=['<Shift><Super>exclam']
move-to-workspace-2=['<Shift><Super>at']
move-to-workspace-3=['<Shift><Super>numbersign']
move-to-workspace-4=['<Shift><Super>dollar']
move-to-workspace-5=['<Shift><Super>percent']
move-to-workspace-6=['<Shift><Super>asciicircum']
move-to-workspace-7=['<Shift><Super>ampersand']
move-to-workspace-8=['<Shift><Super>asterisk']
move-to-workspace-9=['<Shift><Super>parenleft']
switch-to-workspace-4=['<Super>4']
switch-to-workspace-1=['<Super>1']
switch-to-workspace-10=['<Super>0']
switch-to-workspace-3=['<Super>3']
switch-to-workspace-8=['<Super>8']
switch-to-workspace-5=['<Super>5']
move-to-workspace-10=['<Shift><Super>parenright']
switch-to-workspace-2=['<Super>2']
switch-to-workspace-9=['<Super>9']
switch-to-workspace-6=['<Super>6']
switch-to-workspace-7=['<Super>7']

View File

@@ -348,6 +348,13 @@ install_main() {
cleanup cleanup
} }
install_dconf() {
which dconf >/dev/null 2>&1 || return 1
find "${BASEDIR}/dconf" -type f -printf '/%P\n' | while read dcpath ; do
dconf load ${dcpath}/ < "${BASEDIR}/dconf/${dcpath}"
done
}
# Setup variables # Setup variables
read_saved_prefs read_saved_prefs
@@ -401,6 +408,10 @@ case $OPERATION in
# Do nothing, just sourcing # Do nothing, just sourcing
set +o errexit set +o errexit
;; ;;
dconf)
# Load dconf
install_dconf
;;
*) *)
echo "Unknown operation $OPERATION." >/dev/stderr echo "Unknown operation $OPERATION." >/dev/stderr
exit 1 exit 1