Make publish command conditional in case someone else is publishing