ç¥æ¸ãã¸ãã§Scalaã§ãªãã話ãããã«Scalaãèµ·åãããã¨ãããã¤ã³ã¹ãã¼ã«ããã¦ãªãã£ãã®ã§ã»ããã¢ããããã¨ãã®è©±ã
-
-
- -
-
Macãªã®ã§Scalaã¯brewã§ã¤ã³ã¹ãã¼ã«ãã¾ãã
brew install scala
ãã£ã±ã¤ãããã§scalaã¯ä½¿ãããã§ããã©ãvimã§æ¸ãæã®ãã¤ã©ã¤ãã欲ãããªããã©ãããsbazã£ã¦ã®ã§scala-tool-supportãã¤ã³ã¹ãã¼ã«ããããã®ä¸ã«ãããããã
ã§ãsbazï¼ãããªã³ãã³ããªããâ¦ã
ã©ããç§ãbrewã§ã¤ã³ã¹ãã¼ã«ããscala-2.9.2ã«ã¯å
¥ã£ã¦ããªã模æ§ãscala-2.9.1ãã¤ã³ã¹ãã¼ã«ãããå
¥ã£ã¦ããã¡ã¨ã¢ã¬ã³ã¬ããã®ã§ã¡ã¢ã£ã¦ããã
éå»ãã¼ã¸ã§ã³ã®ã¤ã³ã¹ãã¼ã«ã¯ãversionsã§è¦ã¦ãcheckoutãã¦ãinstallããã
$ brew versions scala 2.9.2 git checkout 9201a0c /usr/local/Library/Formula/scala.rb 2.9.1-1 git checkout 2e7cbfe /usr/local/Library/Formula/scala.rb 2.9.1 git checkout b78cfbd /usr/local/Library/Formula/scala.rb 2.9.0.1 git checkout cb1ab23 /usr/local/Library/Formula/scala.rb 2.9.0 git checkout 4002978 /usr/local/Library/Formula/scala.rb 2.8.1 git checkout 0e16b9d /usr/local/Library/Formula/scala.rb 2.8.0 git checkout fdb41a3 /usr/local/Library/Formula/scala.rb 2.7.7 git checkout 6a18e38 /usr/local/Library/Formula/scala.rb 2.7.6 git checkout a82e823 /usr/local/Library/Formula/scala.rb 2.7.5 git checkout e9dd256 /usr/local/Library/Formula/scala.rb $ cd /usr/local $ git checkout b78cfbd /usr/local/Library/Formula/scala.rb $ brew install scala
ãããªæããåã®ãå ¥ã£ã¦ããuninstallã¨ãunlinkã¨ããã®è¾ºãã«ããã«ããã¦ãããããããã¨/usr/local/binã«ãããã¡ã¤ã«ãéªéã§ã©ã¼ãã¼ãªã£ããé©å½ã«rmãã
è¤æ°ãã¼ã¸ã§ã³å ¥ãã¦ãæã«infoãããå ¥ã£ã¦ãã ãã§ã¦ãä»ä½¿ã£ã¦ãã®ã« * ãã¤ãã
$ brew info scala scala: stable 2.9.2 http://www.scala-lang.org/ /usr/local/Cellar/scala/2.9.1 (3186 files, 98M) /usr/local/Cellar/scala/2.9.2 (38 files, 26M) * https://github.com/mxcl/homebrew/commits/master/Library/Formula/scala.rb ==> Caveats Bash completion has been installed to: /usr/local/etc/bash_completion.d
ã¤ã³ã¹ãã¼ã«æ¸ãã§ããã¤ã¯switchã§åãæ¿ããããã brew switch scala 2.9.2 ã¨ããããªæããã§ããªããä¸æãè¡ããªãæãã ã£ãã®ã§ãèªåã§ãã«ããã«ãããã°ããªããããã
sbazã§ã¤ã³ã¹ãã¼ã«ããã®ã㯠/usr/local/Cellar/scala/2.9.1/libexec/misc ã«å ¥ãããã®ä¸ã® scala-tool-support/vim ããç®å½ã¦ã®ãã£ã¬ã¯ããªããã¨ã¯ pathogen 使ã£ã¦ããã .vim/bundle ã«æ¾ãè¾¼ãã§çµäºã
$ cp -r /usr/local/Cellar/scala/2.9.1/libexec/misc/scala-tool-support/vim/ ~/.vim/bundle/scala-tool-support
ã¡ãã£ã¨æ°æã¡æªããã¨ã«ãªã£ã¦ãã
$ ls -al /usr/local/bin | grep scala lrwxr-xr-x 1 irof admin 29 7 24 22:43 fsc -> ../Cellar/scala/2.9.2/bin/fsc lrwxr-xr-x 1 irof admin 30 7 24 22:32 sbaz -> ../Cellar/scala/2.9.1/bin/sbaz lrwxr-xr-x 1 irof admin 36 7 24 22:32 sbaz-setup -> ../Cellar/scala/2.9.1/bin/sbaz-setup lrwxr-xr-x 1 irof admin 31 7 24 22:43 scala -> ../Cellar/scala/2.9.2/bin/scala lrwxr-xr-x 1 irof admin 32 7 24 22:43 scalac -> ../Cellar/scala/2.9.2/bin/scalac lrwxr-xr-x 1 irof admin 34 7 24 22:43 scaladoc -> ../Cellar/scala/2.9.2/bin/scaladoc lrwxr-xr-x 1 irof admin 32 7 24 22:43 scalap -> ../Cellar/scala/2.9.2/bin/scalap