2016-10-22 2 views
3

저는 하스켈을 배우고 Emacs 개발 환경 (this)을 설정하려고합니다.
내가해야 할 일 중 하나는 hindent을 설치하는 것입니다.
권장 방법 here은 단지 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에 그것은 확장 나를 adviced 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 결과 끝에서 등 (이다 아마 이전에 추가 된 사람들의 종속성하는) 새로운 종속성을 제안 무엇을 제안 할 때 몇몇 두 종속물은 unmet 버전을 가지고있다.

암시 적 종속성을 얻는 것이 빌드 도구의 일이라고 생각하므로 구성 (또는 스택 이해)에 문제가 있다고 생각합니다.

경험이 많은 사람이 초보자 잘못이 무엇인지 추측 할 수 있습니까?

+2

글로벌 프로젝트의 리졸버가'ghc-7.10.3' 인 특별한 이유가 있습니까? (문제의 원인이 될 수 있습니다.) – duplode

답변

4

ghc 버전을 리졸버로 사용하는 것은 일반적으로 권장하지 않습니다. 수동으로 많은 패키지 버전을 지정해야합니다. 대신 lts-6.23이나 다른 비슷한 것으로 전환하는 것이 좋습니다.

+0

고맙습니다. 지금까지 본 다른 생태계의 표준 빌드 도구와는 의미가 있지만 약간 다릅니다. 'lts-6.23' 또는'lts-7.5'을 통해 설치되는'hindent' 버전은 버전 <5이지만 5가 필요합니다. 나는 내가 필요한 것을 얻기 위해 야간으로 전환했다. 내 이유는 스택 철학에 따라 맞습니까? 아니면 어딘가에 단일 패키지 ('hindent')의 특정 버전을 지정해야합니까? – foki

+1

명령 행에서 hindent 버전을 지정할 수는 있지만 원하는 버전으로 야간 스냅 샷을 선택하는 것이 좋습니다. –

0

확실하지 않습니다. 그냥 빨리 움직이기를 원한다면 :

stack upgrade --git && \ 
rm -rf ~/.stack  && \ 
stack setup   && \ 
stack install hindent 

GHC 8.X와 새로운 새로운 스택을 사용하지 않는 이유는 무엇입니까? ;)