typesafe激活器依赖错误

时间:2015-02-19 10:49:13

标签: scala playframework typesafe-activator typesafe

我只是下载最后一个激活器版本(版本1.2.12 - 离线分发),当我按照文档创建一个新的scala项目(https://www.playframework.com/documentation/2.3.x/NewApplication)时,我发现了一些依赖错误。

如何获得未解决的依赖? 我可以像mvn一样安装:安装缺少的依赖项吗?

[info] Updating {file:/home/myhome/workspaceScala/play-scala/project/}play-scala-build...
[info] Resolving com.typesafe.play#routes-compiler_2.10;2.3.8 ...
[error] Server access Error: Connection timed out url=http://repo.scala-sbt.org/scalasbt/sbt-plugin-releases/com.typesafe.play/routes-compiler_2.10/2.3.8/ivys/ivy.xml
[error] Server access Error: Connection timed out url=http://repo.scala-sbt.org/scalasbt/sbt-plugin-releases/com.typesafe.play/routes-compiler_2.10/2.3.8/jars/routes-compiler_2.10.jar
[info] Resolving commons-io#commons-io;2.0.1 ...
[error] Server access Error: Connection timed out url=http://repo.scala-sbt.org/scalasbt/sbt-plugin-releases/commons-io/commons-io/2.0.1/ivys/ivy.xml
[info] Resolving com.typesafe.play#sbt-run-support_2.10;2.3.8 ...
[error] Server access Error: Connection timed out url=http://repo.scala-sbt.org/scalasbt/sbt-plugin-releases/com.typesafe.play/sbt-run-support_2.10/2.3.8/ivys/ivy.xml
[error] Server access Error: Connection timed out url=http://repo.scala-sbt.org/scalasbt/sbt-plugin-releases/com.typesafe.play/sbt-run-support_2.10/2.3.8/jars/sbt-run-support_2.10.jar

1 个答案:

答案 0 :(得分:0)

谢谢singhakash和Sarvesh,这是一个网络问题。

我认为最好的解决方案是设置环境变量ACTIVATOR_OPTS。 我将此行添加到我的.bashrc文件(〜/ .bashrc):

export ACTIVATOR_OPTS="-Dhttp.proxyUser=MyProxyAccount -Dhttp.proxyPassword=MyProxyPwd -Dhttp.proxyHost=MyProxyIp -Dhttp.proxyPort=MyProxyPort"

非常感谢