Austin Agile DevOps

DevOps in the Cloud
posts - 70 , comments - 7 , trackbacks - 0

February 2016 Entries

TeamCity Build Number from Most Recent Git Tag + 1 Dash Short Sha
We want a semantic version build number derived from the most recent git tag that follows a three-node semantic version format. We use GitLab and here’s how we do that in TeamCity. 1. Add a Powershell build step as follows: $lastVerTag = git describe --abbrev=0 --tags --match [0-99][.][0-99][.][0-999] [string]$majMin = $lastVerTag.Substring(0,$la... [int]$incr = $lastVerTag.Substring($last... $incr = $incr + 1 $semVer = $majMin + '.' + $incr $Hash = "%build.vcs.number%" ......

Posted On Tuesday, February 16, 2016 12:42 PM | Comments (0) |

Powered by: