I've added a PowerShell task to checkout a branch and commit some changes once TFSBuild has already cloned my TFS-hosted GIT repository.
It looks like this:
$gitBranch = $env:BUILD_SOURCEBRANCH.Split("/")[-1] git checkout $gitBranch git add ../sql/ git commit -m "Updated database backup" git push
Once I queue a build and it gets executed, it gets stuck on
1 file changed, 1071 insertions(+) create mode 100644 sql/web.sql
I can't figure out how can I fix this issue, because when I run the whole command in the build machine from a Powershell command line, it works flawlessly.