Improve travis scripts

Now we will always build html, even on pull requests, and the checking
for whether or not to push is more robust.  I'm going to push this directly, because it only touches travis and doesn't really change functionality much.