title: Accessing teamcity parameters in kotlin DSL
body: <p>I am creating a kotlin DSL for a TeamCity project, and want to get the current branch name in the actual kotlin script.</p>
  <p>If I run a script step, the current branch renders correctly</p>
  <pre class="lang-java prettyprint-override"><code>script {
      name=&quot;print branch&quot;
      scriptContent = &quot;&quot;&quot;echo &quot;Branch is  %teamcity.build.branch%&quot;&quot;&quot;&quot;
  }
  </code></pre>
  <p>From the actual <code>settings.kts</code>, I don't seem to have access to it</p>
  <pre class="lang-kotlin prettyprint-override"><code>val currentBranch = DslContext.getParameter(&quot;teamcity.build.branch&quot;) //yields '&lt;placeholder-1&gt;'
  </code></pre>
  <p>How can I get this parameter in my Kotlin code?</p>