Use home folder rather than `~/.var`, for config files

Is it possible to put configuration files of Flatpak’s on the home folder (~/.config, ~/.local same as regular programs) rather than in ~/.var

I am a user, who wants to transition some programs from Arch packages to Flatpak, and I do not want to create 100s of symlinks
I understand that the current behavior is done to make isolating access permissions easier, but it comes at the cost of usability

You can add --filesystem=xdg-config and --filesystem=xdg-data as a global override through Flatseal.

Hey thanks,
i can figure out where to put those arguments on flatseal (I am interacting from the GUI program, i can not find its config files)

Hey thanks,
i can figure out where to put those arguments on flatseal (I am interacting from the GUI program, i can not find its config files)

image

image
hopefull this works

edit: it does not work)

No just put xdg-config, click the + button on right corner, add xdg-data

image
Does not work, the apps still use .var/app for their config files

I don’t think it’s implemented to be changeable, the values for XDG_CACHE_HOME, XDG_CONFIG_HOME & XDG_DATA_HOME get hardcoded when the application runs (flatpak/common/flatpak-context.c at dc2ce2cb0bed88e5206917346220784b383aac3b · flatpak/flatpak · GitHub). There’s no easy or clean way around that.

xdg-config is supposed to bind mount host’s xdg-config into ~/.var/app/$FLATPAK_ID/config but looks like it only works when a subdirectory is specified like xdg-config/foobar:create, presumably for security reasons.

So basically instead of a global override, you have to do this on a per-app basis, by checking what the config directory of each app is and add that as an override in Flatseal liks xdg-config/foo.

Can you please send screenshot (sorry, I do not understand GUI options from text)