I'm trying to instal sbt based project to local maven repository. I have tried commands:
"sbt publish"
- require repository credentials"sbt publish-local"
install to .ivy repositry, but I need maven! How can I do such operation in terms of SBT?
The SBT wiki has the goods. Just define the repo (look for "Publishing to the users local maven repository" on the linked page) and invoke "publish".
Using SBT 0.13 and without editing the project source files:
Create (or edit) a global.sbt
file in ~/.sbt/0.13
:
vim ~/.sbt/0.13/global.sbt
Add the following line:
publishTo := Some(Resolver.file("file", new File(Path.userHome.absolutePath+"/.m2/repository")))
Save and close the file
sbt publish
from the project folderIf 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