読者です 読者をやめる 読者になる 読者になる

Mac OSX Emacs で、Scala -- ensimeをいれる。

そして、ensime

MacBook:~ g$ curl -O http://cloud.github.com/downloads/aemoncannon/ensime/ensime_2.8.1-0.5.0.tar.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 26.5M  100 26.5M    0     0  1278k      0  0:00:21  0:00:21 --:--:-- 1684k

MacBook:~ g$ tar zxvf ensime_2.8.1-0.5.0.tar.gz -C .emacs.d/
x ensime_2.8.1-0.5.0/
x ensime_2.8.1-0.5.0/README.md
x ensime_2.8.1-0.5.0/lib/
x ensime_2.8.1-0.5.0/lib/maven-artifact-manager-2.2.1.jar
x ensime_2.8.1-0.5.0/lib/org.scala-refactoring.library_0.3.0.201103291443.jar
x ensime_2.8.1-0.5.0/lib/nekohtml-1.9.6.2.jar
x ensime_2.8.1-0.5.0/lib/xercesMinimal-1.9.6.2.jar
x ensime_2.8.1-0.5.0/lib/plexus-utils-1.5.15.jar
x ensime_2.8.1-0.5.0/lib/core-3.4.2.v_883_R34x.jar
x ensime_2.8.1-0.5.0/lib/maven-settings-2.2.1.jar
x ensime_2.8.1-0.5.0/lib/ensime_2.8.1-0.5.0.jar
x ensime_2.8.1-0.5.0/lib/wagon-file-1.0-beta-6.jar
x ensime_2.8.1-0.5.0/lib/classworlds-1.1-alpha-2.jar
x ensime_2.8.1-0.5.0/lib/asm-commons-3.2.jar
x ensime_2.8.1-0.5.0/lib/ant-1.6.5.jar
x ensime_2.8.1-0.5.0/lib/implicitNotFound.jar
x ensime_2.8.1-0.5.0/lib/critbit-0.0.4.jar
x ensime_2.8.1-0.5.0/lib/ant-launcher-1.8.1.jar
x ensime_2.8.1-0.5.0/lib/scala-compiler.jar
x ensime_2.8.1-0.5.0/lib/wagon-http-shared-1.0-beta-6.jar
x ensime_2.8.1-0.5.0/lib/maven-ant-tasks-2.1.0.jar
x ensime_2.8.1-0.5.0/lib/wagon-http-lightweight-1.0-beta-6.jar
x ensime_2.8.1-0.5.0/lib/maven-project-2.2.1.jar
x ensime_2.8.1-0.5.0/lib/maven-model-2.2.1.jar
x ensime_2.8.1-0.5.0/lib/scalariform_2.8.1-0.0.9.jar
x ensime_2.8.1-0.5.0/lib/ant-1.8.1.jar
x ensime_2.8.1-0.5.0/lib/backport-util-concurrent-3.1.jar
x ensime_2.8.1-0.5.0/lib/maven-profile-2.2.1.jar
x ensime_2.8.1-0.5.0/lib/scala-library.jar
x ensime_2.8.1-0.5.0/lib/maven-repository-metadata-2.2.1.jar
x ensime_2.8.1-0.5.0/lib/maven-plugin-registry-2.2.1.jar
x ensime_2.8.1-0.5.0/lib/plexus-interpolation-1.11.jar
x ensime_2.8.1-0.5.0/lib/plexus-container-default-1.0-alpha-9-stable-1.jar
x ensime_2.8.1-0.5.0/lib/maven-artifact-2.2.1.jar
x ensime_2.8.1-0.5.0/lib/ivy-2.1.0.jar
x ensime_2.8.1-0.5.0/lib/wagon-provider-api-1.0-beta-6.jar
x ensime_2.8.1-0.5.0/lib/asm-tree-3.2.jar
x ensime_2.8.1-0.5.0/lib/asm-3.2.jar
x ensime_2.8.1-0.5.0/lib/maven-error-diagnostics-2.2.1.jar
x ensime_2.8.1-0.5.0/elisp/
x ensime_2.8.1-0.5.0/elisp/popup.el
x ensime_2.8.1-0.5.0/elisp/ensime-inf.el
x ensime_2.8.1-0.5.0/elisp/ensime-doc.el
x ensime_2.8.1-0.5.0/elisp/ensime-search.el
x ensime_2.8.1-0.5.0/elisp/ensime-undo.el
x ensime_2.8.1-0.5.0/elisp/ensime-config.el
x ensime_2.8.1-0.5.0/elisp/ensime-debug.el
x ensime_2.8.1-0.5.0/elisp/ensime.el
x ensime_2.8.1-0.5.0/elisp/auto-complete.el
x ensime_2.8.1-0.5.0/elisp/ensime-refactor.el
x ensime_2.8.1-0.5.0/elisp/fuzzy.el
x ensime_2.8.1-0.5.0/elisp/ensime-auto-complete.el
x ensime_2.8.1-0.5.0/elisp/ensime-test.el
x ensime_2.8.1-0.5.0/elisp/ensime-sbt.el
x ensime_2.8.1-0.5.0/elisp/ensime-builder.el
x ensime_2.8.1-0.5.0/bin/
x ensime_2.8.1-0.5.0/bin/server.bat
x ensime_2.8.1-0.5.0/bin/server
x ensime_2.8.1-0.5.0/LICENSE

MacBook:~ g$ cd .emacs.d/

MacBook:.emacs.d g $ ln -s ensime_2.8.1-0.5.0 ensime

init.elに、以下を追記。

;; Load the ensime lisp code...
(add-to-list 'load-path "~/.emacs.d/ensime/elisp/")
(require 'ensime)

;; This step causes the ensime-mode to be started whenever
;; scala-mode is started for a buffer. You may have to customize this step
;; if you're not using the standard scala mode.
(add-hook 'scala-mode-hook 'ensime-scala-mode-hook)

;; MINI HOWTO: 
;; Open .scala file. M-x ensime (once per project)

OKかな。