我在學習Haskell並嘗試設置我的Emacs開發環境(請閱讀this)。
我應該做的一件事是安裝hindent
。
推薦方法0只是stack install hindent
。我想它應該安裝在堆棧的global-project
空間中。在$HOME/.stack/global-project/stack.yaml
我的全球棧YAML是:Haskell堆棧的基本用法失敗
flags: {}
extra-package-dbs: []
packages: []
extra-deps: []
resolver: ghc-7.10.3
我不使用任何系統ghc
(有我的$PATH
沒有ghc
或ghci
)。
在stack install hindent
就勸我向extra-deps
:
Run from outside a project, using implicit global project config
Using resolver: ghc-7.10.3 from implicit global project's config file: /home/me/.stack/global-project/stack.yaml
While constructing the build plan, the following exceptions were encountered:
In the dependencies for hindent-5.2.1:
descriptive must match >=0.7 && <0.10, but the stack configuration has no specified version
(latest applicable is 0.9.4)
exceptions must match -any, but the stack configuration has no specified version (latest applicable is 0.8.3)
haskell-src-exts must match >=1.18, but the stack configuration has no specified version
(latest applicable is 1.18.2)
monad-loops must match -any, but the stack configuration has no specified version (latest applicable is 0.4.3)
mtl must match -any, but the stack configuration has no specified version (latest applicable is 2.2.1)
path must match -any, but the stack configuration has no specified version (latest applicable is 0.5.9)
path-io must match -any, but the stack configuration has no specified version (latest applicable is 1.2.0)
text must match -any, but the stack configuration has no specified version (latest applicable is 1.2.2.1)
unix-compat must match -any, but the stack configuration has no specified version (latest applicable is 0.4.2.0)
utf8-string must match -any, but the stack configuration has no specified version (latest applicable is 1.0.1.1)
yaml must match -any, but the stack configuration has no specified version (latest applicable is 0.8.20)
Recommended action: try adding the following to your extra-deps in /home/me/.stack/global-project/stack.yaml:
- descriptive-0.9.4
- exceptions-0.8.3
- haskell-src-exts-1.18.2
- monad-loops-0.4.3
- mtl-2.2.1
- path-0.5.9
- path-io-1.2.0
- text-1.2.2.1
- unix-compat-0.4.2.0
- utf8-string-1.0.1.1
- yaml-0.8.20
當我提出它提出了一些新的依賴(這可能是依賴關係的那些前加入的)等。在它導致situatuation結束其中一些兩個依賴項具有未滿足的版本。
我認爲我的配置(或理解堆棧)有問題,因爲我認爲獲得隱式依賴關係是構建工具的工作。
有人更有經驗可以推斷出我的初學者有什麼錯?
爲什麼你的全球項目中的解析器是'ghc-7.10.3'有什麼特別的理由嗎? (我認爲這可能是您問題的根源。) – duplode