Skip to content

Conversation

@pbrinkmeier
Copy link
Contributor

@pbrinkmeier pbrinkmeier commented Apr 3, 2024

Addresses #390

This works in a fresh haskell:9.6.4-lite Docker container and will download necessary dependencies. It should continue to work for the foreseeable future. There's some minor formatting changes too, let me know if they're okay with you.

@ocramz ocramz self-requested a review April 7, 2024 06:01
README.md Outdated
```bash
stack exec -- scotty-basic
$ cabal run scotty-basic
Setting phasers to stun... (port 3000) (ctrl-c to quit)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you keep the stack example?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This command does not work when I test it in a recent fresh haskell Docker container. stack run [...] does, but only if a stack.yaml is present. If we keep this I'd suggest adding a stack.yaml file too so that it works out of the box, thoughts (see #390)?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, adding a stack.yaml is not a good practice because it forces a fixed resolver on the users.

Indeed, I agree that the current stack example is not self-contained because it assumes a stack init && stack build.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

stack run -- scotty-basic works without stack build before but still requires a stack.yaml. I can try whether stack init && stack run ... works though. I guess for their own projects people can use whichever tool they want anyways.

@pbrinkmeier
Copy link
Contributor Author

Hey, what's your opinion here? Should we add a stack.yaml to make it possible to do stack run or maybe add a hint for Stack users that it won't work out of the box even though it's compatible?

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.

2 participants