Installing Snaps from other shells than Bash

Hi all,

I have installed Libreoffice and Mailspring via Snap, and was wondering why these applications were not really integrated into my KDE Neon installation - no file associations, no menu entries etc. It took me quite a while to figure out that the reason for this was that I use fish (and not bash) as my default shell (I believe the problem would be the same with zsh). Removing the snaps, changing my shell to bash and reinstalling them solved all issues.

Long story short, I think there should be at least a warning when a user is trying to install a snap from a different shell. Many users will, like me, have switched to zsh or fish for some fancy feature or another, and then stopped thinking about that - I would have never realised myself that that could be the reason for my problems!

The best advice I found online (which could maybe be included in the warning) is to use chsh to change to bash, and then adding the command for your favoured shell to the end of the .bashrc.

Keep up the good work,
Tobi

this is:

1 Like

Just for the record, installing/removing snaps works regardless of the shell. What does not work is setting the $PATH and adding the location of desktop files from snaps. Things are explained in the context of zsh in the bug report @ogra linked. The case is probably similar with fish.

If you feel like working on fish support for a bit, feel free to open a PR to the snapd repo. I’m sure other fish users would also be happy to see this improved.

3 Likes