2016-07-14 118 views

回答

14

documentation for the stack.yamlpackages section给出了涉及更复杂的包位置的示例。

packages: 
- location: . 
- location: dir1/dir2 
- location: https://example.com/foo/bar/baz-0.0.2.tar.gz 
- location: http://github.com/yesodweb/wai/archive/2f8a8e1b771829f4a8a77c0111352ce45a14c30f.zip 
- location: 
    git: [email protected]:commercialhaskell/stack.git 
    commit: 6a86ee32e5b869a877151f74064572225e1a0398 
- location: 
    hg: https://example.com/hg/repo 
    commit: da39a3ee5e6b4b0d3255bfef95601890afd80709 

然后加入extra-dep: truepackage进入只是告诉stack不要把它在拉的东西你正在开发的(例如,不加载它GHCI)的代码。

+0

这个答案似乎过时了。您可以在extra-deps下指定url和文件路径 – Flip