scalariform 不下载依赖项

scalariform not downloading dependency

当我尝试安装 scalariform 插件时:

build.sbt :

resolvers += Resolver.typesafeRepo("releases")

addSbtPlugin("org.scalariform" % "sbt-scalariform" % "1.6.0")

我收到 sbt 错误:

[

trace] Stack trace suppressed: run last *:update for the full output.
[error] (*:update) sbt.ResolveException: unresolved dependency: com.typesafe.sbt#sbt-scalariform;1.6.0: not found
[error] Total time: 1 s, completed 24-Mar-2016 23:51:57
>

我需要特定版本的 scalari 插件吗?

下面的项目结构有效。似乎无法从 build.sbt 添加插件,需要在 /project/plugins.sbt.

/project/plugins.sbt :

addSbtPlugin("org.scalariform" % "sbt-scalariform" % "1.6.0")

build.sbt :

scalariformSettings

.scala 文件需要在文件夹 src/main/scala 中才能被 scalariform

格式化