Seems over complicated, here is the same thing with make and older csc tasks (taken from my blog here: <a href="http://flukus.github.io/2016/11/30/2016_11_30_Rediscovering-Make/" rel="nofollow">http://flukus.github.io/2016/11/30/2016_11_30_Rediscovering-...</a>):<p><pre><code> Version ?= 2.0.0.1
$(version): $(init)
sed s'/$${Version}/$(Version)/g' src/Version.template.cs > build/Version.cs
</code></pre>
Not to mention it's doing a lot of other things I would call anti-patterns, like running differently if it's on the CI server ("if(bambooRelease)") and checking in build artifacts.