I didn't think I'd need to ever note this down but, since the setup guide on flatpak.org can cause you to make a really annoying mistake:
If you're gonna be adding the flathub repository, which, most likely you are if you're using flatpak,
then DON'T put sudo before the command when it just fucking fails.. Which is 'cause the
devs didn't specify shit about this in the instructions and THEN it'd get installed SYSTEM-WIDE :OO
!! woooow
And what does that mean?
ИДЕНТИФИКАТОР Клон Оп Отдалечено хранилище Изтегляне 1. [✗] org.freedesktop.Platform.GL.default 25.08 i flathub 141,3 MB / 142,3 MB 2. [✗] org.freedesktop.Platform.GL.default 25.08-extra i flathub 25,6 MB / 142,4 MB 3. [/] org.freedesktop.Platform.GL.nvidia-580-142 1.4 i flathub 1,0 kB / 331,3 MB 4. [ ] org.freedesktop.Platform.Locale 25.08 i flathub < 379,1 MB 5. [ ] org.freedesktop.Platform.VAAPI.nvidia 25.08 i flathub < 50,3 kB 6. [ ] org.freedesktop.Platform.codecs-extra 25.08-extra i flathub < 14,4 MB 7. [ ] org.freedesktop.Platform 25.08 i flathub < 252,6 MB 8. [ ] dev.vencord.Vesktop stable i flathub < 123,4 MB ВНИМАНИЕ: Failed to get revokefs-fuse socket from system-helper: Launch helper exited with unknown return code 1 ВНИМАНИЕ: Launch helper exited with unknown return code 1 ВНИМАНИЕ: Failed to get revokefs-fuse socket from system-helper: Launch helper exited with unknown return code 1 ВНИМАНИЕ: Launch helper exited with unknown return code 1 ВНИМАНИЕ: Failed to get revokefs-fuse socket from system-helper: Launch helper exited with unknown return code 1 Инсталиране 3/8… 0% 0 байта/s
Flatpak will default to installing shit system-wide. And when it does that... It asks for your password in the background to write to your system folders and basically does it anyway. Flat-fucking-pak.
Maybe it's asking for a password prompt but there's some "password helper tool" that is broken or
nonexistent by default on a minimalist distro like Void? I don't even know. Anyways that could be
fixed by just adding sudo again but this isn't good flatpak practice actually.. I mean,
don't ask me why I added the flathub repo with sudo in the first place. I don't know either.
So, how do you actually add the flathub repository you might ask?
flatpak remote-add --user --if-not-exists flathub https://dl.flathub.org/repo/flathub.flatpakrepo
..the same fucking command but just with the --user flag. Ok.
And only then does it actually work as intended.
And the official setup guide says NOTHING about any of this.
dmenu
For some reason, and I'm not entirely sure why, flatpaks are NOT showing up in dmenu, and I tried quite a few things. The only workaround I found is creating a tiny executable wrapper script in your local binary directory so dmenu can see it and launch it. This is how:
sudo tee /usr/local/bin/<binary-name><< 'EOF' # for example, `vesktop` #!/bin/sh exec flatpak run<YOUR.APPLICATION.ID>"$@" # for example, `dev.vencord.Vesktop` EOF
Then
sudo chmod +x /usr/local/bin/<binary-name>
And clear the dmenu cache with rm -f ~/.dmenu_cache ~/.cache/dmenu_run
Sidenote
For Vesktop (or other Discord clients), do
# Change Vesktop's app ID to whatever you're using
flatpak override --user --filesystem=home dev.vencord.Vesktop
so that flatpak's sandboxing doesn't get in the way of accessing your home directory.