publish-to-github.sh should exit in case an error occurred during the site generation in order to avoid pushing a half generated site. E.g. http://ci.hibernate.org/job/www.hibernate.org/25/console pushed out an update with many pages missing due to a generation error.