私は数年間コーディングをしていませんでしたが、今はゲームに戻ろうとしています。非常に単純な scala プロジェクトHelloWorldをセットアップしようとしていますが、sbt コンソールからコンパイルしようとすると、次のエラー メッセージが表示されます。Eclipse プロジェクト設定を生成するためにsbteclipseプラグインを追加していました。
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn] :: UNRESOLVED DEPENDENCIES ::
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn] :: com.typesafe.sbteclipse#sbteclipse-plugin;4.0.0: not found
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn]
[warn] Note: Some unresolved dependencies have extra attributes. Check that these dependencies exist with the requested attributes.
[warn] com.typesafe.sbteclipse:sbteclipse-plugin:4.0.0 (scalaVersion=2.11, sbtVersion=0.13)
[warn]
[warn] Note: Unresolved dependencies path:
[warn] com.typesafe.sbteclipse:sbteclipse-plugin:4.0.0 (scalaVersion=2.11, sbtVersion=0.13) (/Users/michael/Development/Scala-Testings/HelloWorld/project/plugins.sbt#L3-4)
[warn] +- default:helloworld-build:0.1-SNAPSHOT (scalaVersion=2.11, sbtVersion=0.13)
sbt.ResolveException: unresolved dependency: com.typesafe.sbteclipse#sbteclipse-plugin;4.0.0: not found
私は、scalaバージョン2.11.8とbrewからインストールされたsbt 0.13.12を備えたmacOS Sierraを使用しています。
プロジェクトのディレクトリ構造
src
+- main
+- scala
+- HelloWorld.scala
project
+- plugins.sbt
build.sbt
build.sbt の内容
name := "HelloWorld"
version := "1.0"
scalaVersion := "2.11.8"
plugins.sbt の内容
logLevel := Level.Warn
addSbtPlugin("com.typesafe.sbteclipse" % "sbteclipse-plugin" % "4.0.0")
HelloWorld.scala の内容
object HelloWorld extends App {
def main (args Array[String]) : Unit = {
println ("HelloWorld!")
}
}