Can be done with travis-ci and [conditional releases](https://docs.travis-ci.com/user/deployment#Conditional-Releases-with-on%3A).