我正在尝试使用 sbt 生成本教程中描述的 ensime 配置文件:
http://jawher.net/2011/01/17/scala-development-environment-emacs-sbt-ensime/
我遇到的问题是我无法让 sbt 生成配置文件,因为“ensime generate”命令似乎不是 sbt 命令集的一部分。
[输出]
[info] Building project ScalaTest 1.0 against Scala 2.9.2
[info] using sbt.DefaultProject with sbt 0.7.7 and Scala 2.7.7
[error] No method named 'ensime' exists.
[info] Execute 'help' for a list of commands or 'actions' for a list of available project actions and methods.
[info]
[info] Total time: 0 s, completed 26-Jan-2013 12:53:48
[info]
[info] Total session time: 0 s, completed 26-Jan-2013 12:53:48
[error] Error during build.
[后续步骤]
cd <project directory> (sbt project root)
sbt 'ensime generate'
[版本信息]
sbt 0.7.7
ensime 2.9.2-0.9.8.1
scala 2.9.2
[emacs配置]
(add-to-list 'load-path "~/.emacs.d/scala-emacs")
(require 'scala-mode-auto)
(add-hook 'scala-mode-hook
'(lambda ()
(scala-mode-feature-electric-mode)
))
(require 'scala-mode)
(add-to-list 'auto-mode-alist '("\\.scala$" . scala-mode))
(add-to-list 'load-path "~/.emacs.d/ensime/elisp/")
(require 'ensime)
(add-hook 'scala-mode-hook 'ensime-scala-mode-hook)
(push "/media/xxx/Development/Runtimes/scala-2.9.2/bin/" exec-path)
(push "/media/xxx/Development/Tools/sbt/" exec-path)
任何帮助表示赞赏(我已经检查了所有路径,所以请不要对此发表评论)
干杯,
爱