未知神器 sbtplugin 使用 scala 2.12 的超级安全编译器 [英] Unknown artifact sbtplugin Super safe compiler with scala 2.12

查看:50
本文介绍了未知神器 sbtplugin 使用 scala 2.12 的超级安全编译器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我的 Scala 2.12 sbt 项目中,我使用的是 IntelliJ IDEA 并且想要导入 Scalatest.为了安装推荐的 SuperSafe Community Edition Scala 编译器插件.我按照此处的说明进行操作.

In my sbt project in Scala 2.12 I am using IntelliJ IDEA and want to import scalatest. In order to install the recommended SuperSafe Community Edition Scala compiler plugin. I followed the instruction here.

我的plugin.sbt:

addSbtPlugin("com.artima.supersafe" % "sbtplugin" % "1.1.2")

Intellij 导入显示的错误是:

the error showed by the Intellij import is:

        SBT project import
        [warn]  [FAILED     ] com.artima.supersafe#sbtplugin;1.1.2!sbtplugin.jar(src):  (0ms)
        [warn] ==== typesafe-ivy-releases: tried
        [warn]   https://repo.typesafe.com/typesafe/ivy-releases/com.artima.supersafe/sbtplugin/scala_2.10/sbt_0.13/1.1.2/srcs/sbtplugin-sources.jar
        [warn] ==== sbt-plugin-releases: tried
        [warn]   https://repo.scala-sbt.org/scalasbt/sbt-plugin-releases/com.artima.supersafe/sbtplugin/scala_2.10/sbt_0.13/1.1.2/srcs/sbtplugin-sources.jar
        [warn] ==== local: tried
        [warn]   /Users/salvob/.ivy2/local/com.artima.supersafe/sbtplugin/scala_2.10/sbt_0.13/1.1.2/srcs/sbtplugin-sources.jar
        [warn] ==== public: tried
        [warn]   https://repo1.maven.org/maven2/com/artima/supersafe/sbtplugin_2.10_0.13/1.1.2/sbtplugin-1.1.2-sources.jar
        [warn] ==== Artima Maven Repository: tried
        [warn]   http://repo.artima.com/releases/com/artima/supersafe/sbtplugin_2.10_0.13/1.1.2/sbtplugin-1.1.2-sources.jar
        [warn]  ::::::::::::::::::::::::::::::::::::::::::::::
        [warn]  ::              FAILED DOWNLOADS     ... 

可能与新的 Scala 版本不兼容?

Maybe incompatility with new Scala Version?

推荐答案

尝试以下操作:

  • 当我们在projects/build.sbt中添加插件时:

  • When we add the plug-in in projects/build.sbt:

addSbtPlugin("com.artima.supersafe" % "sbtplugin" % "1.1.2")

添加到~/.sbt/0.13/global.sbt

resolvers +=Artima Maven Repository"在http://repo.artima.com/releases"

确保在每个 sbt 行之前和之后都有一个空行

Make sure you have an empty line before and after each of the sbt lines

HTH

这篇关于未知神器 sbtplugin 使用 scala 2.12 的超级安全编译器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆