From 4a5960cc6000099ffccf4dcde33ec7feb72dc56a Mon Sep 17 00:00:00 2001 From: jakubsuchybio Date: Sat, 5 Oct 2019 11:24:49 +0200 Subject: [PATCH 1/4] Update teamcity docs with info about fetchallheads --- docs/build-server-support/build-server/teamcity.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/docs/build-server-support/build-server/teamcity.md b/docs/build-server-support/build-server/teamcity.md index dfc061cdd8..5f0afad080 100644 --- a/docs/build-server-support/build-server/teamcity.md +++ b/docs/build-server-support/build-server/teamcity.md @@ -17,13 +17,18 @@ TeamCity has support for meta-runners which allow custom tasks. There is a GitVe - [Project Link](https://github.com/JetBrains/meta-runner-power-pack/tree/master/gitversion) ## Running inside TeamCity -When running in TeamCIty you have two options, run using **agent checkout** or use dynamic repositories. +When running in TeamCity you have two options, run using **agent checkout** or use dynamic repositories. ### Agent checkout For GitVersion to pick up pull requests properly you need to promote the `%teamcity.build.vcs.branch.{configurationid}%` variable to an environment variable called `Git_Branch` Just go to your build configuration, Parameters, click Add, Name should be `env.Git_Branch`, value should be `%teamcity.build.vcs.branch.{vcsid}%` where vcsid is your VCS root id. You should get auto completion for this. +For GitVersion to work with [MainLine mode](../../reference/mainline-development.md) you need to set configuration parameter `teamcity.git.fetchAllHeads = true`, because TeamCity by default fetches only current branch for building, but MainLine mode requires master for calculating version. +More reference about this #912, #1199, #1234, #1441, #1477 and #1825 + +Again go to your build configuration, Parameters, click Add, Name should be `teamcity.git.fetchAllHeads`, value should be `true`. + ### Dynamic repositories To use server side checkout, you must use the dynamic repositories feature of GitVersion. Server side checkout sends just the files to the agent and not the actual .git folder. Dynamic repositories will clone your repo into a temp folder and use it to calculate version information. From 0fc5aa48e4cee17c394fea577eaac8263a1acd53 Mon Sep 17 00:00:00 2001 From: Jakub Suchy Date: Sat, 5 Oct 2019 11:54:28 +0200 Subject: [PATCH 2/4] Update teamcity docs with asbjornu suggestion MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Asbjørn Ulsberg --- docs/build-server-support/build-server/teamcity.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/build-server-support/build-server/teamcity.md b/docs/build-server-support/build-server/teamcity.md index 5f0afad080..d5f624145c 100644 --- a/docs/build-server-support/build-server/teamcity.md +++ b/docs/build-server-support/build-server/teamcity.md @@ -24,7 +24,7 @@ For GitVersion to pick up pull requests properly you need to promote the `%teamc Just go to your build configuration, Parameters, click Add, Name should be `env.Git_Branch`, value should be `%teamcity.build.vcs.branch.{vcsid}%` where vcsid is your VCS root id. You should get auto completion for this. -For GitVersion to work with [MainLine mode](../../reference/mainline-development.md) you need to set configuration parameter `teamcity.git.fetchAllHeads = true`, because TeamCity by default fetches only current branch for building, but MainLine mode requires master for calculating version. +For GitVersion to work with any mode requiring other than the currently built branch to calculate the version number, you need to set the configuration parameter [`teamcity.git.fetchAllHeads = true` in TeamCity](https://www.jetbrains.com/help/teamcity/git.html#Git-GeneralSettings), because TeamCity by default fetches only the current branch for building. More reference about this #912, #1199, #1234, #1441, #1477 and #1825 Again go to your build configuration, Parameters, click Add, Name should be `teamcity.git.fetchAllHeads`, value should be `true`. From a701354b212b4fc8e1c957f8fc9b7b6edefe7159 Mon Sep 17 00:00:00 2001 From: Jakub Suchy Date: Sat, 5 Oct 2019 11:58:11 +0200 Subject: [PATCH 3/4] Update teamcity docs with asbjornu suggestion MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Asbjørn Ulsberg --- docs/build-server-support/build-server/teamcity.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/build-server-support/build-server/teamcity.md b/docs/build-server-support/build-server/teamcity.md index d5f624145c..bc6a70dc61 100644 --- a/docs/build-server-support/build-server/teamcity.md +++ b/docs/build-server-support/build-server/teamcity.md @@ -27,7 +27,7 @@ Just go to your build configuration, Parameters, click Add, Name should be `env. For GitVersion to work with any mode requiring other than the currently built branch to calculate the version number, you need to set the configuration parameter [`teamcity.git.fetchAllHeads = true` in TeamCity](https://www.jetbrains.com/help/teamcity/git.html#Git-GeneralSettings), because TeamCity by default fetches only the current branch for building. More reference about this #912, #1199, #1234, #1441, #1477 and #1825 -Again go to your build configuration, Parameters, click Add, Name should be `teamcity.git.fetchAllHeads`, value should be `true`. +To add this configuration parameter to your build configuration, go to *Parameters*, click *Add*, *Name* should be `teamcity.git.fetchAllHeads` and the value should be `true`. ### Dynamic repositories To use server side checkout, you must use the dynamic repositories feature of GitVersion. Server side checkout sends just the files to the agent and not the actual .git folder. Dynamic repositories will clone your repo into a temp folder and use it to calculate version information. From 80a6793676ff128446e5fa42da133971e555cad3 Mon Sep 17 00:00:00 2001 From: jakubsuchybio Date: Sat, 5 Oct 2019 11:57:31 +0200 Subject: [PATCH 4/4] Remove issue references --- docs/build-server-support/build-server/teamcity.md | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/build-server-support/build-server/teamcity.md b/docs/build-server-support/build-server/teamcity.md index bc6a70dc61..3c66a62773 100644 --- a/docs/build-server-support/build-server/teamcity.md +++ b/docs/build-server-support/build-server/teamcity.md @@ -25,7 +25,6 @@ For GitVersion to pick up pull requests properly you need to promote the `%teamc Just go to your build configuration, Parameters, click Add, Name should be `env.Git_Branch`, value should be `%teamcity.build.vcs.branch.{vcsid}%` where vcsid is your VCS root id. You should get auto completion for this. For GitVersion to work with any mode requiring other than the currently built branch to calculate the version number, you need to set the configuration parameter [`teamcity.git.fetchAllHeads = true` in TeamCity](https://www.jetbrains.com/help/teamcity/git.html#Git-GeneralSettings), because TeamCity by default fetches only the current branch for building. -More reference about this #912, #1199, #1234, #1441, #1477 and #1825 To add this configuration parameter to your build configuration, go to *Parameters*, click *Add*, *Name* should be `teamcity.git.fetchAllHeads` and the value should be `true`.