1

I want to trigger a build in TFS when a merge request in GitLab gets created/updated. GitLab creates a ref for each merge request:

refs/merge-requests/id/head

When I use the following branch specification TFS doesn't trigger.:

refs/merge-requests/*

That's probably caused by the fact that TFS doesn't fetch that ref. Also in my local repo I need to add a line to git config to fetch it:

[remote "origin"]
url = https://server/repo.git
fetch = +refs/heads/:refs/remotes/origin/
fetch = +refs/merge-requests//head:refs/remotes/origin/merge-requests/

When TFS internally uses a git repo to fire triggers, then I can change that config in TFS's repo. I searched the TFS server and build agents for a git repo that might be used for triggering builds, but I didn't find one.

Is there a way to tell TFS to fetch and trigger on such a ref?

I don't want to use services, hooks or anything, because this seems to be a straightforward solution and I can't afford spending much time on it now.

Thanks!

Edwin
  • 71
  • 1
  • 5
  • Not sure this works. But it worth to give it a try [this](https://stackoverflow.com/a/38731565/7073340) – Jayendran Sep 05 '18 at 02:34

0 Answers0