Update 2 files
- /home/.chezmoiscripts/universal/run_onchange_after_25-gnome-extension-settings.tmpl - /home/.chezmoiscripts/universal/run_onchange_after_21-dconf-settings.tmpl
This commit is contained in:
parent
49148f1473
commit
99cc32e825
2 changed files with 17 additions and 1 deletions
|
@ -12,7 +12,15 @@ logg info 'Backed up system dconf settings to '"$DCONF_TMP"
|
|||
### Reset system settings / load saved configurations from ~/.config/dconf/settings
|
||||
if [ -d "$XDG_CONFIG_HOME/dconf/settings" ]; then
|
||||
find "$XDG_CONFIG_HOME/dconf/settings" -mindepth 1 -maxdepth 1 -type f | while read DCONF_CONFIG_FILE; do
|
||||
DCONF_SETTINGS_ID="/$(basename "$DCONF_CONFIG_FILE" | sed 's/\./\//')"
|
||||
if [ "$DEBUG_MODE" == 'true' ]; then
|
||||
logg info 'Dconf configuration file:'
|
||||
echo "$DCONF_CONFIG_FILE"
|
||||
fi
|
||||
DCONF_SETTINGS_ID="/$(basename "$DCONF_CONFIG_FILE" | sed 's/\./\//')/"
|
||||
if [ "$DEBUG_MODE" == 'true' ]; then
|
||||
log info 'Dconf settings ID:'
|
||||
log info "$DCONF_SETTINGS_ID"
|
||||
fi
|
||||
# Reset dconf settings if environment variable RESET_DCONF is set to true
|
||||
if [ "$RESET_DCONF" == 'true' ]; then
|
||||
logg info 'Resetting dconf settings for `'"$DCONF_SETTINGS_ID"'`'
|
||||
|
|
|
@ -44,7 +44,15 @@ fi
|
|||
### Apply plugin gsettings
|
||||
if [ -f "$HOME/.config/desktop/gnome.yml" ]; then
|
||||
cat "$HOME/.config/desktop/gnome.yml" | yq e -o=j '.' | jq -cr '.default_gnome_extensions[]' | while read EXT; do
|
||||
if [ "$DEBUG_MODE" == 'true' ]; then
|
||||
logg info 'Extension data:'
|
||||
echo "$EXT"
|
||||
fi
|
||||
EXT_ID="$(echo "$EXT" | jq -r '.regex')"
|
||||
if [ "$DEBUG_MODE" == 'true' ]; then
|
||||
logg info 'Extension ID:'
|
||||
echo "$EXT_ID"
|
||||
fi
|
||||
EXT_SETTINGS_TYPE="$(echo "$EXT" | jq -r '.settings | type')"
|
||||
EXT_SETTINGS="$(echo "$EXT" | jq -r '.settings')"
|
||||
if [ "$EXT_SETTINGS" != 'null' ]; then
|
||||
|
|
Loading…
Reference in a new issue