Add error checking, and only push if there are changes.
Merge pull request #5 from teknico/add-error-checking

Add error checking, and only push if there are changes.