Skip to content

Instantly share code, notes, and snippets.

@pesblog
Last active December 22, 2015 19:49
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save pesblog/6522682 to your computer and use it in GitHub Desktop.
Save pesblog/6522682 to your computer and use it in GitHub Desktop.

前提: scalaとplayはbrewでインストール済み

$ cd $$PROJECT_DIR$$
$ rm -rf .idea .idea_modules
$ play
[PROJECT_NAME] $ compile
[PROJECT_NAME] $ idea no-fsc no-sbt-build-module
  • Intellij IDEAでプロジェクトを開く
  • Play 2 のコメント欄の Ignore をクリック
  • ProjectSettinsを開く
    • SDKs に Java1.7 を追加する(追加されてることもある)

    • Global Libraries に brew-scala を追加
      // 追加するpath
      /usr/local/opt/scala/idea/lib/scala-compiler.jar
      /usr/local/opt/scala/idea/lib/scala-library.jar
      /usr/local/opt/scala/idea/lib/scala-reflect.jar

    • Facets > Scala ($$PROJECT_NAME$$) を開いて compiler にさっき作った brew-scala を選択する

* errorが2つ位なので、両方ともFixをクリックしてRemove ~~を実行する ※新しいバージョンではでなくなりました。

  • メニューのRun→Edit Configurations... を開いて Defaults→Play 2 Appを選択
    • Use non-default Play 2 install dirにチェックを入れて下記パスを入力
      /usr/local/opt/play/libexec
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment