Thank you for the response, however those issues aren’t quite the same as what I’m seeing. As it turns out, I am actually familiar with that problem, it’s a issue with TravisCI as well. If CircleCI operates similarly, then there’s no real solution - Travis checks outs tag which puts the local repo in
a headless state i.e. it’s not tied to a specific branch. The best you can do is run
git branch --contains I found that that approach wasn’t 100% reliable either.
Regarding my issue, I want to run the deploy job if and only if, a tag commit has been pushed and I want it to run sequentially after the test job which should run after the build job.
In other words:
- The build job always runs.
- The test job always runs, unless the build job fails.
- The deploy job runs only for tag commits and only if build and test both succeed.
It seems like I should be able to make that flow work somehow in my config.yml file.