How to build only when branch has changes?
currently we have 2 projects for 2 branches of a bitbucket repository.
When changes is merged to one of the branch, both project will start the building process.
Is there a way that the project with changes in its branch build only. The other project with no changes in its branch should do nothing.
Comments are currently closed for this discussion. You can start a new one.
Keyboard shortcuts
Generic
| ? | Show this help |
|---|---|
| ESC | Blurs the current field |
Comment Form
| r | Focus the comment reply box |
|---|---|
| ^ + ↩ | Submit the comment |
You can use Command ⌘ instead of Control ^ on Mac

Support Staff 1 Posted by Feodor Fitsner on 16 Oct, 2013 05:02 PM
Hm, I see the problem.
Both hooks are called, but only one should trigger build. I will file a bug and fix it in the next update.
Just curious, is it possible that the same push into remote repository could have commits for several branches?
2 Posted by Steven Thuriot on 17 Oct, 2013 08:03 AM
I don't think it is unlikely to push changes to several branches at once, depending on how often you push. I personally commit a lot, but mostly push only once a day.
It's probably safer to check commit id's rather than pushes.
3 Posted by mcpken on 17 Oct, 2013 08:14 AM
Actually we merge pull request that goes to one branch.
From what I checked, other branch is not updated.
Support Staff 4 Posted by Feodor Fitsner on 17 Oct, 2013 02:10 PM
OK, what if we make a list of all branches affected by the push (check all commits in GitHub/BitBucket webhook payload) and trigger new builds for corresponding projects?
5 Posted by mcpken on 18 Oct, 2013 12:02 AM
Yes I think that works. since each project is setup for 1 branch in the
setting.
Support Staff 6 Posted by Feodor Fitsner on 24 Oct, 2013 07:22 PM
Hi guys,
The functionality has been just deployed with the latest AppVeyor update. Now webhook triggers build if only both project's repository and branch match.
Feodor Fitsner closed this discussion on 24 Oct, 2013 07:22 PM.
mcpken re-opened this discussion on 25 Oct, 2013 10:17 AM
7 Posted by mcpken on 25 Oct, 2013 10:17 AM
That's great!
Will check it out.
8 Posted by hannajohn on 14 Sep, 2015 05:18 PM
is this feature still available? if yes, can you please provide an example? I couldn't find documentation
Support Staff 9 Posted by Feodor Fitsner on 14 Sep, 2015 05:20 PM
I think this is it: http://www.appveyor.com/docs/branches
Ilya Finkelshteyn closed this discussion on 25 Aug, 2018 02:00 AM.