How to pass custom version to sbt release?
<p>I need to pass a custom version to the SBT release task. I'm currently running this:</p>

<pre><code>sbt "release with-defaults release-version 1.2.3 next-version 1.3.0"
</code></pre>

<p>But I get this:</p>

<pre><code>[info] Loading project definition from F:\dev\MyProject\project
[info] Set current project to ipo-renew (in build file:/F:/dev/MyProject/)
[error] Expected whitespace character
[error] Expected 'with-defaults'
[error] Expected 'skip-tests'
[error] Expected 'cross'
[error] release with-defaults release-version 20.0.5-XML-Hotfix-1 next-version 20.0.5-XML-Hotfix-2
[error]                       ^
</code></pre>

<p>I've tried without the quotes:</p>

<pre><code>sbt release with-defaults release-version 1.2.3 next-version 1.3.0
</code></pre>

<p>But I then get prompted for a version, rather than it using the ones I've supplied. </p>

<p>As far as I can tell from the sbt release plugin docs (<a href="https://github.com/sbt/sbt-release" rel="nofollow">https://github.com/sbt/sbt-release</a>) I'm passing the right stuff in - any ideas why it's ignored? I eventually need this to work from a command line step in TeamCity...</p>

<p>I've also tried omitting the 'with-defaults' option but it makes no difference to the result. However running just </p>

<pre><code>sbt release with-defaults 
</code></pre>

<p>correctly doesn't prompt me and uses the version we have in version.sbt.</p>