Avoid triggering builds for existing commits being pushed in a new branch.
At the moment, if you push an "empty branch", Buildkite will trigger a build. e.g.
git checkout master
git push # Trigger a build for commit XXXX in branch master
git checkout -b empty-branch
git push # Trigger a second build for commit XXXX in branch empty-branch
It would be nice if Buildkite would check for the existence of a build before triggering a new one.
To be fair this isn't really a bug, it's a fairly normal behavior when you understand git, and all your competitors do the same thing, but we get weekly bug reports about it from our users as they really don't expect it.
We configure "Branch limiting" to "master" so that Buildkite only triggers builds for merges to master and for pull requests into master. So someone pushing to a branch won't trigger until they make a Pull Request.
FYI this breaks the workflow of anyone using grb or who does a workflow like:
- Create a new remote branch off master.
- Commit a change.
- Push that branch.
But that also means I was probably triggering a bunch of builds I wasn't intending to... So I'll just change my workflow.
A different branch name can result in a different build flow. So suppressing a build could be wrong.