2011-11-24 152 views
2

http://cingusoft.posterous.com/install-scala-on-mac-os-x在Mac OSX Lion上安裝scala

我更改了.profile並保存。之後我在第一次鍵入

源的.profile

它的工作原理,但在我關閉終端並重新打開,它不工作。

我該如何解決這個問題?

Getting a Scala interpreter to work

我解決我自己的。

+2

在OS X上,我更喜歡brew來安裝SW。安裝brew:「https://github.com/mxcl/homebrew/wiki/installation」,那麼你可以用「brew install scala」安裝scala或其他工具。和「brew install sbt」 – Fabian

回答

5

您應該將此行添加到您的shell autoload文件中:.bashrc for bash或.zshrc for zsh。

+1

對不起。我不明白。請爲此提供任何代碼?我是unix的新手; – Silvester

+1

如果你輸入'echo $ SHELL',你會發現你使用的是什麼shell。 如果是bash,則必須將'export PATH =「/ Users/your_user/scala/bin:$ PATH」'添加到您的.bashrc文件中。 – mytrile