Open with vscodium when plugging in external storage

After installing vscodium, whenever I plug in an external storage device, in the gnome notification, it says: open in vscodium, instead of the usual open in nautilus. In the app settings (gnome settings) for vscodium, I don’t see any option, and in the Default applications section, there isn’t a way to specify which application to open an external drive with, so I don’t know how to solve the problem. Also, I searched for something that I could change inside of dconf, but I didn’t find anything.

When uninstalling vscodium the problem goes away, but when reinstalling, it starts happening again.


That is a feature - some would call it a bug - in the vscodium package. Address the maintainer at the AUR package page. The vscode (code package) in the repo does not exhibit this behavior.

The possibility to open a folder in vs code does however make sense as often your project is stored inside a folder structure with multiple subfolders and files - it is however nice to know why such behavior emerges.

vscodium publish itself as an inode/directory handler in the .desktop file.

[Desktop Entry]

The differences can be a little confusing - I have decided not to venture an effort to explain - I don’t even quite understand it myself :grin:

You will likely want to keep vscodium package so copy the launcher to your home and remove the inode/directory part. (Do not modify the system file. Changes will be overwritten without warning)

mkdir -p ~/.local/share/applications
cp /usr/share/applications/vscodium.desktop ~/.local/share/applications
gedit ~/.local/share/applications/vscodium.desktop

To have the marketplace and other features you should look into the accompanying packages on aur

I didn’t know that the file handlers were defined in the launcher files, but know that I think about it, it makes thanks. I also didn’t know that you could overwrite launchers over on ~/.local/share/applications, I used to modify them directly, so thanks for that also.

The links you provided are quite interesting, as I didn’t knew there were other ‘oss’ packages for vs-code, I just installed vs-codium because I was switching from atom and wanted to try, but I was having problems with some extensions, so it nice that I can also get my other problems fixed, so I’ll look into it.
Really I have to look more into that, because coming from debian, I just looked for the same packages either in the repos or in the AUR.

Edit: I forgot to mention that for me the launcher has codium.desktop as the name, when I do it with codium.desktop, it doesn’t work, neither reloading the desktop (F2 → R), nor rebooting the computer. It doesn’t work for me either when changing the codium.desktop under /usr/share/applications

Thanks for such an extensive and quick answer, you even fixed some problems that I didn’t even mention!