Only add the sha if we are creating a new commit

@IanVaughan @oturley