Update publish.sh

The doc has to be generated for evolving branches, not for tags.