precommit target is too slow

Following #295, there are many, many examples. The `precommit` target builds and tests all of them, which takes a long time.

Suggestion:

 * Modify `precommit` to do less work
 * Add a `travis` target (or similar) so that the Travis CI server still builds and tests all the examples