2014-10-28 78 views
-1

喜一出新戲的項目,我想創建與SBT(Scala的構建工具),一個播放項目,我很follwing this tutorial如何創建具有SBT

下節「創建新的應用程序,而無需安裝播放」 我follwed相同的指令

這是我的項目/ Build.scala文件

import sbt._ 
import Keys._ 
import PlayProject._ 

object ApplicationBuild extends Build { 
    val appName ="playsbtproj" 
    val appVersion ="1.0" 
    val main = PlayProject(
    appName, appVersion, appDependencies, mainLang =SCALA 
    ) 
} 

,這是我的項目/ plugins.sbt文件

resolvers += "Typesafe repository" at "http://repo.typesafe.com/typesafe/releases/" 

// Use the Play sbt plugin for Play projects 
addSbtPlugin("com.typesafe.play" % "sbt-plugin" % "2.2.3") 

當我在我的項目folers SBT鍵入SBT給了我以下erorrs

[info] Loading project definition from /opt/programs/play/playsbtproj/project 
[info] Compiling 1 Scala source to /opt/programs/play/playsbtproj/project/target/scala-2.10/sbt-0.13/classes... 
[error] /opt/programs/play/playsbtproj/project/Build.scala:3: not found: object PlayProject 
[error] import PlayProject._ 
[error]  ^
[error] /opt/programs/play/playsbtproj/project/Build.scala:8: not found: value PlayProject 
[error]  val main = PlayProject(
[error]    ^
[error] two errors found 
[error] (compile:compile) Compilation failed 
Project loading failed: (r)etry, (q)uit, (l)ast, or (i)gnore? [email protected]:/opt/programs/play/playsbtproj$ 

請幫助我如何解決這個問題

回答