I have recently switched to Fedora Silverblue. The recommended way for development is to use Fedora Toolbox containers, so I have started using it and installed the various development packages there. I like the Devhelp application for browsing the API documentation. So I installed that application over GNOME Software. But the problem is that the Devhelp application started from GNOME Shell doesn’t see the documentation files which are located under the Toolbox container. This is probably expected, but it is annoying. Starting the Devhelp application from the terminal over toolbox run flatpak run org.gnome.Devhelp
is pretty cumbersome.
To solve this issue, I simply copied the org.gnome.Devhelp.desktop
file from /var/lib/flatpak/app/org.gnome.Devhelp/current/active/files/share/applications
to ~/.local/share/applications
and modified the Exec
and DBusActivatable
lines the following way:
Exec=toolbox run flatpak run org.gnome.Devhelp
DBusActivatable=false
Now I can easily start the Devhelp application from GNOME Shell to see all the documentation files from the Toolbox container. I hope that this short post helps other people. Let me know in the comments if there is a better way to achieve this…
EDIT: This solution, unfortunately, stopped working soon after publishing the post. But see the comment section for alternative approaches and choose the one which fits you best.
You’ve hit two weak spots by combining a flatpak app with a toolbox container:
I hope Flatpak and Silvetblue devs are still on track improving integration points, as that’s always been the talking point back in 2019 when I was preaching on Reddit that Flatpak just needs more time polishing those points.
Sorry for not being of help with your problem, but I wanted to chime-in to let you know about a firefox/chrome script I’ve made that when viewing the GNOME API docs online it links to the source code of that API, very useful for development imo.
Check out the demo video:
https://gitlab.gnome.org/nbenitez/gnome-codesearch/uploads/7a04539e0d10c43f31c3f6e1e1565f15/gnome-codesearch-demo.webm
And if you like it you can visit the project page for how to install:
https://gitlab.gnome.org/nbenitez/gnome-codesearch/-/tree/master
And thanks for your gio/gvfs work!! 🙂
The online docs are too slow for me when searching for concrete function in comparison to Devhelp, but your userscript is really cool, so I will maybe reconsider this…
Personally, I’ve been using Devhelp in a flatpak and copying/linking documentation to
~/.var/app/org.gnome.Devhelp/data/gtk-doc
. I don’t know if that’s much better though.Hmm, that requires even more manual work, so nothing for me, but thanks for mentioning it!
Oh no, I did
rpm-ostree upgrade
anddnf update
yesterday and now the suggested approach doesn’t work and I see the following error under Toolbox:$ flatpak run org.gnome.Devhelp
bwrap: Can't find source path /run/user/1000/doc/by-app/org.gnome.Devhelp: No such file or directory
I’ve just filed new issue for it, see toolbox/issues/659.
As per the mentioned bug report, it seems that using Flatpaks from Toolbox is not assumed at all. So I finally installed Devhelp application over
dnf install devhelp
inside the Toolbox and changed theExec
line toExec=toolbox run devhelp
.Thanks for the blog post! This new solution worked for me, in the end. Would you mind putting a pointer to this comment at the top of the blog post? That’d be helpful for future people searching how to get this to work.
Done, thanks for the feedback.
Alternatively installing the flatpak sdk docs (e.g. org.gnome.Sdk.Docs) should work with the Devhelp flatpak.
Thanks for mentioning this, I have not known about this. Unfortunately, it doesn’t contain all the docs I need, but I can imagine that this would be sufficient for a lot of people!