创建Haskell项目时是否需要Setup.hs文件? [英] Do I need Setup.hs file when creating Haskell projects?

查看:90
本文介绍了创建Haskell项目时是否需要Setup.hs文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用 stack new< name> ,然后使用 hpack-convert 并将依赖项添加到 package.yaml 以便跳过仪式并开始编写Haskell代码。

I use stack new <name>, then hpack-convert and add dependencies into package.yaml in order to skip ceremony and start writing Haskell code.

为什么总会有设置.hs 文件?据我所知,我没有使用自定义设置。我是否需要在某个时候包含此文件?

Why is there's always a Setup.hs file? I don't use custom setups as far as I know. Will I need to include this file at some point?

推荐答案

我认为 Setup.hs只是一个古老的haskell约定。即使是简单的构建类型,也可以用来构建软件包。十分确定可以将其删除而不会出现问题。

I think it's just an old haskell convention that "Setup.hs" can be used to build the package, even for simple build types. Pretty sure it can be removed without having issues.

这篇关于创建Haskell项目时是否需要Setup.hs文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆