Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stack support #3

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

ghost
Copy link

@ghost ghost commented Aug 20, 2018

hello,

this commit adds support for builds with stack. I did not use hpack before, so maybe there is a clever way to automate this? If you do not want to integrate this pull request please could you describe in the readme you configure and build flow?

regards,

the cabal file was generated from package.yaml in ZZ_OLD/v1/package.yaml
and then slightly modified so that stack is happy.
@rsnikhil
Copy link
Owner

Dear Polypolen (apologies, I don't know your real name),

[ Apologies for delays in responses; I'm juggling 4-5 projects, so I get back to this one only periodically. ]

I deliberately avoided using 'stack' because the primary audience for these semantics is not familiar with Haskell or Haskell flows, and I wanted to keep it as simple and transparent as possible for them. In the README, there is a section titled 'How to build Forvis ...' which describes how to install ghc with just a few steps, build the executable, and run tests.

'Stack' of course helps a lot when there are a lot of specialized imports, and lots of dependencies on particular versions, etc. I've deliberately avoided any such esoterics, to keep it totally standard Haskell, and simple. I use the phrase 'extremely elementary' Haskell in the README for this.

If you are comfortable with 'stack', cabal files, yaml files etc., please feel free to use them.

@ghost
Copy link
Author

ghost commented Aug 24, 2018

Thanks for your feedback,

I understand your point; doing so you furthermore remove an extra dependency to stack.

However,

  • for the newcomer: it is also possible to ask the user to install stack, and then run stack setup && stack build. IMHO it does not add extra complexity to the initial setup.
  • for more experienced Haskellers, it could be worth describing more precisely your build configuration, e.g. for reproducible builds, even though the list of dependencies is very limited for now.

best regards,

@benjaminselfridge
Copy link

I see no downside to including a cabal file, at the very least. That way Haskellers don't have to do anything extra to build Forvis in a way that's natural for them. The README could simply point out that the repo provides both, and you can build it however you prefer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants