我正在关注http://seanhess.github.io/2015/08/04/practical-haskell-getting-started.html以开始使用堆栈工具。
$> stack --version
Version 0.1.3.1, Git revision 908b04205e6f436d4a5f420b1c6c646ed2b804d7
在“安装 GHC”步骤中,我得到Permission denied
:
$> stack setup
Run from outside a project, using implicit global config
Using resolver: lts-3.2 from global config file: /Users/karl/.stack/global/stack.yaml
Preparing to download ghc-7.10.2 .../Users/karl/.stack/programs/x86_64-osx/ghc-7.10.2.tar.bz2.tmp:
openBinaryFile: permission denied (Permission denied)
这是预期的(指南中的错误)还是中的错误stack
?
运行相同的命令sudo
似乎可以解决问题。这是预期的方法吗?
$> sudo stack setup
Password:
Downloaded ghc-7.10.2.
Installed GHC.
stack will use a locally installed GHC
For more information on paths, see 'stack path' and 'stack exec env'
To use this GHC and packages outside of a project, consider using:
stack ghc, stack ghci, stack runghc, or stack exec
我正在运行全新安装的 OS X 10.10.4 (Yosemite)。