2

How can I prevent sbt-release from prompting user for Release version and Next version?

Johny T Koshy
  • 3,857
  • 2
  • 23
  • 40
saniya saifee
  • 23
  • 1
  • 3

1 Answers1

6

use the with-defaults option:

$ sbt "release with-defaults"
ed.
  • 2,696
  • 3
  • 22
  • 25
  • I tried this option but it is still prompting for version. – saniya saifee Feb 22 '16 at 20:20
  • Thanks ed! I tried this option too but its not working. I get this error: "No versions are set! Was this release part executed before inquireVersions?" – saniya saifee Feb 22 '16 at 22:06
  • sounds like you haven't defined a version for your project. Have you included a `version.sbt` file with `version in ThisBuild := "1.0.0-SNAPSHOT"`? I'd recommend following the docs closely when getting started. – ed. Feb 22 '16 at 22:34
  • I included this file and have followed the the instruction in the tutorial.I am using activator: activator "release with-defaults"instead of sbt "release with-defaults". Can this be the issue? – saniya saifee Feb 22 '16 at 23:04
  • perhaps - at this point you'd have to share your project code to allow any further answers – ed. Feb 23 '16 at 16:20
  • Hi @ed. The issue has been resolved. I was using the latest version of the plugin (1.0.2) and it has some issue with the with-defaults option. https://github.com/sbt/sbt-release/issues/142. I reverted back to old version. Thanks for your help :) – saniya saifee Feb 23 '16 at 16:24
  • good to hear @saniyasaifee - would it be fair to say that my answer is correct? and if so could you mark it as such? – ed. Feb 23 '16 at 16:29