better flatpak handling
This commit is contained in:
parent
d63a3ccf33
commit
d3cddde72f
@ -7,16 +7,8 @@ sync_theme() {
|
||||
[ "$(xfconf-query -c xsettings -p /Xfce/SyncThemes)" != 'true' ] && xfconf-query -c xsettings -p /Xfce/SyncThemes -n -t bool -s true
|
||||
# Apply the current theme with gsettings
|
||||
gsettings set org.gnome.desktop.interface gtk-theme "$theme"
|
||||
|
||||
# Apply the current theme for GTK apps in flatpak
|
||||
|
||||
# Define the path to the flatpak override directory
|
||||
flatpak_override_dir="$HOME/.local/share/flatpak/overrides"
|
||||
# Create the directory if it doesn't exist
|
||||
[ -d "$flatpak_override_dir" ] || mkdir -p "$flatpak_override_dir" || { echo 'failed creating directory!'; return 1; }
|
||||
# Write the theme configuration to the global override file
|
||||
echo "[Environment]
|
||||
GTK_THEME=$theme" > "$flatpak_override_dir/global"
|
||||
# Apply the current theme for the all the GTK flatpaks
|
||||
flatpak override --user --env=GTK_THEME="$theme"
|
||||
}
|
||||
|
||||
sync_font() {
|
||||
|
Loading…
Reference in New Issue
Block a user