GNOME Bugzilla – Bug 779813
flatpakref files aren't downloaded from git.gnome.org
Last modified: 2017-03-13 18:56:17 UTC
.flatpakref files are being hosted on git.gnome.org, with the idea that users can click a download link and have them downloaded from there. Unfortunately, these files are being opened in the browser, rather than being downloaded. This leaves users in a confusing position - instead of getting something they can install, they get a page with some text on it. For an example link, see the Builder "Download" button on http://flatpak.org/apps.html . Would it be possible to configure cgit so that .flatpakref files get downloaded?
Added the mime type handles for .flatpak, .flatpakref and .flatpakrepo. https://infrastructure.gnome.org/browse/puppet/commit/?id=054d1d7990257710317586682491e27e20b89b02 Might take 20 minutes before it activates.
https://git.zx2c4.com/cgit/tree/ui-plain.c#n44 cgit has code disallowing this. ugh.
Thanks for looking at this, Olav! Is there anything else you can try, or is this a dead-end?
This should be fixed Allan, please review.
It works here indeed. Thanks!
Is it me or instead of downloading the .flatparef it downloads the page displaying it.
More info: it works with Web but not with Firefox.
(In reply to Adrien Plazas from comment #6) > Is it me or instead of downloading the .flatparef it downloads the page > displaying it. Ugh, you're right.
fwiw it was working with Builder yesterday, but not now.
Using a LocationMatch actually applies the rule to the resulting generated page while using a FilesMatch doesn't work either as /browse passes the content serving to a cgi-bin script (cgit.cgi) which handles Content-Type via the cgitrc configuration file which has the limitation Olav mentioned earlier.
Let us know if this isn't going to be resolved any time soon, so we know whether we need to do anything about the download links on flatpak.org.
I think the problem was that to download these files you _have_ to click on the 'plain' link. I've restored behaviour and ensured the download only happens for the plain link.
Those links are now taking me to the cgit page for the file - no download and no raw text.
Because http://flatpak.org/apps.html is entirely wrong. Do an s/tree/plain/. Correct: https://git.gnome.org/browse/gnome-apps-nightly/plain/gnome-builder.flatpakref Not correct: https://git.gnome.org/browse/gnome-apps-nightly/tree/gedit.flatpakref Make GNOME great again. Use right link. Not fake link.
(In reply to Olav Vitters from comment #14) ... > Make GNOME great again. Use right link. Not fake link. Done. Thanks - I hadn't noticed the issue with the links.