haskell - 为什么 Cabal 在 cabal 初始化后不问我任何问题
问题描述
当我查看 cabal 教程时,他们总是说 cabal,在cabal init
继续向您询问“一堆问题”(https://www.youtube.com/watch?v=a7R-2vtPLDM)并且当我运行命令时阴谋集团不这样做,而是猜测一切。无论我在 Windows 10 上使用 cygwin 还是 cmd,都会发生这种情况。
控制台输出如下:
Warning: The package list for 'hackage.haskell.org' is 20 days old.
Run 'cabal update' to get the latest list of available packages.
Guessing dependencies...
Generating LICENSE...
Warning: unknown license type, you must put a copy in LICENSE yourself.
Generating Setup.hs...
Generating CHANGELOG.md...
Generating Main.hs...
Generating g.cabal...
Warning: no synopsis given. You should edit the .cabal file and add one.
You may want to edit the .cabal file and add a Description field.
(是的,无论包裹清单是否更新,问题都是一样的)
我如何让阴谋集团像平常一样问我问题?我需要重新安装吗?它也无法识别cabal sandbox init
为命令,但这是另一个问题。
解决方案
似乎在最近版本的 cabal-install 中,必须invoke cabal init --interactive
回答“否”,但“生成一个具有合理默认值的简单项目”问题。
此外,沙盒现在已经过时了;在 cabal 项目中,cabal build
应该安装任何必需的依赖项并构建本地包,而无需创建沙箱。
处理已安装依赖项的新方法(在手册中称为“nix 样式”)比沙盒更好。它避免了 cabal 依赖地狱——就像沙盒一样——也避免了多次构建相同的依赖,因为编译的依赖保存在中央存储中,并且可以跨项目重用。
推荐阅读
- android - How to securely store 3rd Party API keys when back end is provided entirely by 'Back End As A Service'?
- google-cloud-platform - IoT Core Issue with Rasperry PI
- python - Selenium:消息:无效参数:无效的“sameSite”
- apache - 为什么我使用 sudo certbot --apache 后看不到 https 网页
- java - 如何使用 Spring JPA 存储库正确保存具有外键的对象?
- blazor - blazor js interop 未选择 html 元素
- java - 使用 Jasper Report Server rest-api 的 Spring Boot REST App 问题
- javascript - 如何重定向到主页 window.location='URL'?
- python-3.x - discord.py - 发送虚拟 PDF 文件
- command-line - 使用命令行从 RTC 中的组件接受选择性文件夹