我正在尝试使用play框架连接到
mysql数据库.从我自己的搜索,我知道我需要在某处添加此行:
“mysql”%“mysql-connector-java”%“5.1.18”
但是,在每个文档/类似的问题中,它都表示此行要么进入Build.scala文件,要么进入build.sbt文件,我没有这些文件.当我创建我的应用程序(作为一个Java应用程序)时,它只给了我一个build.properties和plugins.sbt,它们位于项目文件夹中.
有谁知道如何添加这条线?我需要创建其中一个文件吗?
我的build.properties文件:
sbt.version=0.13.0
和
plugins.sbt
// Comment to get more information during initialization
logLevel := Level.Warn
// The Typesafe repository
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.1")
更新:添加后
addSbtPlugin(“mysql”%“mysql-connector-java”%“5.1.18”)到我的插件文件中: