perma-id/w3id.org — pull request #59 by stain (2014-11-18 17:09:09+00:00)
Title: Check README/.htaccess using travis-ci.org

This adds a `.travis.yml` for testing the `.htaccess` files at https://travis-ci.org/perma-id/w3id.org

As a `perma-id` organization member on Github you would also need to enable this at https://travis-ci.org/profile -

Travis will also be able to add comments to pull requests to say if it passes the tests (as you can see by the little (:heavy_check_mark:) icon next to the Commit in the list below on this patch).

The test is described in https://github.com/stain/w3id.org/tree/travis-checker#link-checking - basically only URIs that are directly mentioned as `https://w3id.org/something` in the found `README.md` files are checked, at http://localhost/ on the temporary Travis instance (Apache 2 in Ubuntu Precise).

I have added a new [step 3](https://github.com/stain/w3id.org/tree/travis-checker#adding-a-permanent-identifier-to-w3idorg) to the top-level README to suggest adding `*/README.md` for new pull requests.

Examples:

All OK (this patch): https://travis-ci.org/stain/w3id.org/builds/41382536#log-container
404 at destination: https://travis-ci.org/stain/w3id.org/builds/41371490
500 (messed up .htaccess syntax): https://travis-ci.org/stain/w3id.org/builds/41372440

If there's an error, Apache's `error.log` is also shown - which is very useful on `.htaccess` errors..

Note that if there is no mention of a URI sub-tree in any README.md, then it is not tested (and the .htaccess could still be hiding errors) - allowing for redirections that deliberately are 404 or don't talk "browser-HTTP" - I believe the checker would request `Accept: text/html` :)