Pull Request build feature with Revision synchronisation Follow
I have problems with using Pull Request build feature together with Snapshot Dependency with Revisions synchronisation enabled.
So we have two repositories: RepoA and RepoB. RepoB has Snapshot Dependency on RepoA with Revisions synchronisation enabled. So when we run a build on RepoB on branch featA, first build is ran on RepoA on the branch with the same name (featA). This works perfectly and is a mandatory feature because RepoB wouldn't work with artifacts of RepoA if it wasn't built on the branch with the same name.
Now the problem is: we wanted to trigger a build on every pull request (we are using GitHub). So if a new PR is created on RepoB, it should first build RepoA and then RepoB, but it should use a branch with the same name to build both of them. So this is an example:
1. I create a PR from branch featB on RepoA
2. Then I create a PR from branch featB on RepoB
3. PR should trigger build of RepoB on branch featB
4. It should first build RepoA (because of dependency) but using the branch featB
What actually happens is that PR triggers build of RepoB but not on branch featB but on "branch" called pull/<ID>. So when snapshot dependency triggers build of RepoA it is looking for branch called pull/<ID> and it doesn't finds it, so it builds using master branch.
Is it possible to synchronise revisions while using the Pull Request build feature? Maybe if it ran a build on the real source branch instead of a pull/<ID> branch.
Please sign in to leave a comment.