I'm trying to upgrade my sbt version from 0.12.3 to 0.13.0 but after it's trying to load a project I get following error:
! is not a member of String
Error occurs in line where I execute external command:
("tar cf " + (buildRoot / "SOURCES").toString + "/" + ver + ".tar -C " + buildRoot.toString + " dir").!
In previous version all was fine.
Does anyone know what I'm doing wrong or what has changed in the newest version?
Edit: Problem resolved. It's needed to add:
import sbt.Process._
in object where are you trying to use postfixOps for example:
val success:Int = ((dir / "script.sh" toString) !)
The ! command (for processes) either comes from sbt's process API or from Scala's.
If you're planning to use sbt's logging with forking (HIGHLY recommend), then you want to make sure you import sbt.Process._
Also, you proabbly want to have your code look more like:
val logger: sbt.Logger = ??? //(usually streams.value.log)
val success:Int = (dir / "script.sh" toString) ! logger
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With