do not push to remote when nothing has changed

Current `publish.sh` pushes to remote when nothing has changed, causing the shell script to exit with error (status 1). This becomes problem when running `./publish.sh` from Jenkins. This pull-req fixes the problem.