added || exit 1 to publish shell script lines that might fail in the middle of the script