1
0
mirror of https://github.com/dcarrillo/dotfiles.git synced 2024-12-22 23:08:01 +00:00

Rename install.sh to config.sh and add a parameter to dump dconf configs

This commit is contained in:
Daniel Carrillo 2020-01-19 19:33:39 +01:00
parent 844bbd1223
commit 03e717ee41
3 changed files with 34 additions and 5 deletions

View File

@ -2,7 +2,7 @@
set -e set -e
dotfiles() copy_dotfiles()
{ {
echo "[INFO] Installing dot files..." echo "[INFO] Installing dot files..."
@ -34,15 +34,39 @@ dconf_loader()
echo "" echo ""
} }
dconf_dumper()
{
if ! command -v dconf > /dev/null 2>&1; then
echo "[WARNING] dconf command not found"
echo ""
return 1
else
for file in dconf/*; do
dconf_conf=$(grep -E -m1 '^#.+dconf-path=.+$' "$file")
dconf_path=$(echo "$dconf_conf" | cut -f2 -d "=")
echo "[INFO] Dumping $dconf_path to $(basename "$file")..."
printf "%s\n\n" "$dconf_conf" > "$file"
dconf dump "$dconf_path" >> "$file"
done
fi
echo ""
}
main() main()
{ {
cd "$(dirname "$0")" cd "$(dirname "$0")"
dotfiles if [ x"$1" = x"--dump-dconf" ]; then
dconf_dumper
else
copy_dotfiles
dconf_loader dconf_loader
fi
cd - > /dev/null cd - > /dev/null
} }
main main "$1"

View File

@ -32,9 +32,10 @@ show-activities-button=true
show-appmenu=false show-appmenu=false
show-favorites=false show-favorites=false
show-show-apps-button=false show-show-apps-button=false
show-showdesktop-button=false show-showdesktop-button=true
stockgs-keep-dash=true stockgs-keep-dash=true
taskbar-position='LEFTPANEL_FIXEDCENTER' taskbar-position='LEFTPANEL_FIXEDCENTER'
trans-bg-color='#000000'
trans-panel-opacity=1.0 trans-panel-opacity=1.0
trans-use-custom-bg=true trans-use-custom-bg=true
trans-use-custom-opacity=true trans-use-custom-opacity=true

View File

@ -1,4 +1,8 @@
# dconf-path=/org/gnome/shell/extensions/topicons/ # dconf-path=/org/gnome/shell/extensions/topicons/
[/] [/]
icon-saturation=0.5
icon-size=24
icon-spacing=6 icon-spacing=6
tray-order=1
tray-pos='right' tray-pos='right'