I use git thread with teamcity as my CI server. I would like to pull artifacts from the last successful build on a specific branch.
I can use this url to get the latest build on the branch: http://$teamcity$/httpAuth/app/rest/buildTypes/name:$BuildTypeName$/builds/branch:name:$branchName$
but it fails if the branch name contains / (e.g. git thread name branches feature/% and release/% ).
I tried url / encoding. For example, if $branchName$> == 'release/branchName' I use /builds/branch:name:release%2F$branchName$) .
- works -
/builds/branch:name:develop - fails -
/builds/branch:name:release%2F$branchName$ .
I am not getting an API error, but the api result is empty.
git rest teamcity
Chris mckenzie
source share