-
Notifications
You must be signed in to change notification settings - Fork 841
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
Document how stack uses the Cabal library in Architecture.md #4494
Document how stack uses the Cabal library in Architecture.md #4494
Conversation
Based on conversation with @snoyberg
5cf2fa7
to
514abbe
Compare
The bulk of the content may belong in a different document. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great, thanks! Some comments added.
doc/faq.md
Outdated
|
||
1. The version used to compile stack, which is not necessarily present on stack users’ machines. | ||
|
||
Stack will always be compiled using the most recent stable version of Cabal-the-library. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not really true. We may attempt to do that, but we could for example release a point release of an older Stack release without upgrading to the newest Cabal library version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added 'where possible' and made clear this refers to releases.
doc/faq.md
Outdated
|
||
5. Stack uses `ghc-pkg` to identify the Cabal version it should use for the setup executable for a build. | ||
The build output is stored in a directory `.stack-work/dist/Cabal-xxxxx` named for the Cabal version used to compile the setup executable. | ||
Together, this means it is only possible to know for sure which Cabal version ought to be used if the corresponding compiler is installed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess details about global-hints.yaml
will appear in the master branch as a part of docs updates for the next release?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah — I didn't know that global-hints.yaml
was new. What should we say here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As far as I understand the idea behind that file is to have information about boot packages without having GHC installed, currently it's used in (to be removed) Stack.Snapshot
and in https://github.com/commercialhaskell/stack/blob/master/src/Stack/SourceMap.hs#L196 but that's actual for master
, not for stable
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've indicated this will change in stack 2.0
The remaining comments will be addressed through a refactor of the text.
Two commits:
I still have a few things left to do, here (e.g. the TODO). |
I need to put this in a new document, rather than the FAQ. Also, I'd like to rebase to take advantage of working CI on |
I think this is ready, in terms of content (assuming the latest addition is correct; it is what my logs suggest though I haven't dug into the code). It should go in a new file, though, rather than the FAQ (perhaps with the 'What is the relationship between stack and cabal' bit directly above, too). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for all the work here @dbaynard!
Actually, I moved the new material into |
Relates to #3049, #4475, #4488.
Please include the following checklist in your PR: