/snap/bin only added to path of root

Hi,

I installed snapd on Debian testing. It seems that /snap/bin has only been added to the path of root, but not for my normal user. Any ideas?
Also I do not see any desktop integration, should I not see snap-store somewhere in the xfce menu after I installed it?
Otherwise it seems to work.

Thank you & Regards,
Fraggle

1 Like

About the path, have you restarted you graphical session for the change to PATH to be taken into account?

About snap-store, it is itself a snap you can install with:

sudo snap install snap-store

Yes, I even have rebooted. root has the path set, normal user not.
I have already installed snap-store, my question was if it should appear somewhere in the menu.

Found the reason, /etc/profile.d/apps-bin-path.sh is ignored for non-login shells.

Note that $XDG_DATA_DIRS, like $PATH, is set in /etc/profile.d/apps-bin-path.sh but also /usr/lib/environment.d/990-snapd.conf. I think setting XDG_DATA_DIRS is required for the snaps to appear in the menu.

Now the question remains why $XDG_DATA_DIRS and $PATH are not set in graphical sessions - perhaps the difference you see between root and users is actually a difference between graphical sessions and login sessions? The cause might be the windows manager for example.

See for example:

xfce just ignores these config files. the solution was to source it in .xsessionrc. thx!