To run a flatpak app from dmenu, you can create a symlink for the app in /usr/bin
.
You can find the flatpak apps binary link in /var/lib/flatpak/exports/bin/
on ubuntu.
E.g. to run Rocket Chat (installed from flatpak via software center), you can do something like this:
sudo ln -s /var/lib/flatpak/exports/bin/chat.rocket.RocketChat /usr/bin/rocket-chat
This way you will be able to find it in the dmenu.
Resources:
reason why i only need to cut out com. and org. is because sometimes some maintainers like to name their apps org."company"."appname", and org."appname"."company" if spotify and other apps just named like "company"."appname" my modification of the script wouldve been 100 % functional and basically cut out all the pain from flatpaks allowing to launch them without weird naming.