Skip to content

Consistently serve useful things as text #176

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ghost opened this issue Jan 4, 2014 · 2 comments · Fixed by #353
Closed

Consistently serve useful things as text #176

ghost opened this issue Jan 4, 2014 · 2 comments · Fixed by #353

Comments

@ghost
Copy link

ghost commented Jan 4, 2014

I'm not exactly sure what the problem is, but please observe how [0] is served as text, whilst [1] is not. This means that users need to download [1] to read it. This is inconvenient e.g. when doing QA on a package repository.

[0] http://hackage.haskell.org/package/random-1.0.1.1/random.cabal
[1] http://hackage.haskell.org/package/fastcgi-3001.0.2.4/src/fastcgi.cabal

@hesselink
Copy link
Contributor

Ah, so the cabal file server from the direct link on the package page is served as text/plain, while the one you get by following the 'browse' link gives you application/x-cabal. I'm pretty sure this comes from Happstack's default mime map.

@ghost
Copy link
Author

ghost commented Jan 4, 2014

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

On 04/01/14 21:28, Erik Hesselink wrote:

Ah, so the cabal file server from the direct link on the package
page is served as text/plain, while the one you get by following
the 'browse' link gives you application/x-cabal. I'm pretty sure
this comes from Happstack's [default mime map].
Sounds like a reasonable conclusion


Alexander
[email protected]
http://plaimi.net/~alexander
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.22 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iF4EAREIAAYFAlLIb3YACgkQRtClrXBQc7U9mgEAgYDCM+aZ3FGS/4S07YUTW/8G
YaC+R3Gm+dVs+ZQro3oA/iVrZH35Hhe2ZVwI026iHzuOx5MtshYDlUt/9g9EenLe
=Ux47
-----END PGP SIGNATURE-----

bergmark added a commit to bergmark/hackage-server that referenced this issue May 4, 2015
@bergmark bergmark mentioned this issue May 4, 2015
stepcut added a commit to Happstack/happstack-server that referenced this issue Sep 18, 2015
Change MIME type of .cabal files to text/x-cabal

There does seem to be any official standard. hackage uses text/plain:

haskell/hackage-server#176

But I can agree that text/x-cabal is better than application/x-cabal.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant