Skip to content
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

exclude all but latest documentation from search results #750

Closed
bos opened this issue May 24, 2012 · 2 comments
Closed

exclude all but latest documentation from search results #750

bos opened this issue May 24, 2012 · 2 comments

Comments

@bos
Copy link
Contributor

bos commented May 24, 2012

(Imported from Trac #760, reported by warren on 2010-11-04)

When searching for haskell documentation on google, quite frequently the top search results are versions of the library documentation from the archives. For instance, when searching for Data.Vector, the top hit is version 0.5, whereas the latest is 0.7. Also, if the user selects the 0.7 version, it isn't obvious from the documentation that this version corresponds to the latest since it also appears in the archive (the url is http://hackage.haskell.org/packages/archive/vector/0.7/doc/html/Data-Vector.html).

So I'm wondering if it might not make sense to exclude all but the latest haddock documentation from search results by augmenting the robots.txt file.

It might also make sense to provide alternate urls to the latest versions of documents. E.g. Starting from the http://hackage.haskell.org/package/vector page (which is the latest version), and clicking on Data.Vector, one is taken to http://hackage.haskell.org/packages/archive/vector/0.7/doc/html/Data-Vector.html... but it might be better if this were http://hackage.haskell.org/packages/current/vector/doc/html/Data-Vector.html. This would allow for all files under /archive to be excluded.

@bos
Copy link
Contributor Author

bos commented May 24, 2012

(Imported comment by guest on 2010-11-04)

We had a brief discussion today in #haskell, and somebody had the good idea of using a <meta rel=canonical> tag.

It seems this would avoid outright excluding old versions, but still making it clear to the search engine which is preferred (i.e. the latest docs). Seems to be a good balance.

If this solution is chosen, this would probably be a haddock issue (not a hackage issue anymore).

Google's documentation on canonical: http://www.google.com/support/webmasters/bin/answer.py?answer=139394

@ttuegel
Copy link
Member

ttuegel commented Feb 25, 2015

Whether this is a Haddock issue or a Hackage issue, it is certainly not a Cabal issue.

@ttuegel ttuegel closed this as completed Feb 25, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants