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

New freeze command #3503

Merged
merged 4 commits into from
Jun 25, 2016
Merged

New freeze command #3503

merged 4 commits into from
Jun 25, 2016

Conversation

dcoutts
Copy link
Contributor

@dcoutts dcoutts commented Jun 20, 2016

Adds a new-freeze command, the freeze command to go along with the other new project-based commands.

See also #3502

@dcoutts
Copy link
Contributor Author

dcoutts commented Jun 20, 2016

No detail from the appveyor build. No report from travis?

@hvr
Copy link
Member

hvr commented Jun 20, 2016

@dcoutts appveyor seems to fail recently for no obvious reason; no travis report is odd though

( normal )

#if !MIN_VERSION_base(4,8,0)
import Data.Monoid (Monoid(mempty))
Copy link
Member

Choose a reason for hiding this comment

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

If this is the only reason for CPP, we can avoid this by referring to mempty at least once qualified...

@23Skidoo
Copy link
Member

Passes on both AppVeyor and Travis now.

@@ -235,6 +235,7 @@ rebuildInstallPlan :: Verbosity
-> FilePath -> DistDirLayout -> CabalDirLayout
-> ProjectConfig
-> IO ( ElaboratedInstallPlan
, ElaboratedInstallPlan
Copy link
Member

Choose a reason for hiding this comment

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

It'd be nice to add some comments explaining the return type.

@23Skidoo
Copy link
Member

LGTM modulo comments.

@dcoutts
Copy link
Contributor Author

dcoutts commented Jun 25, 2016

So I think I'll squash the fixup patches and merge. I've noted some related TODOs in #3104.

@23Skidoo
Copy link
Member

Great, let's merge.

It takes a solver plan, makes an "elaborated plan" with nix style hashes
but still of mostly source package and then does an improvement phase to
make a plan with pre-existing packages from the store.

Previously it only returned the improved plan, but for some things it's
also useful to see the original elaborated plan with the source
packages. In partciular it will be useful for plan.json status output.
It will also be needed for the freeze command to be able to get at the
flag choices, since this info is not preserved in installed packages.
There are various related properties here like packages that are going
to be built locally inplace rather than added to the store, but
sometimes we need to know if a package was originally specified by the
cabal.project file (explicitly or implicitly).
Code to write it and to pick it up by default when reading the
cabal.project file.
This is ok, but not perfect since freezing is now more tricky with setup
deps. See haskell#3502
@dcoutts dcoutts merged commit 108d15a into haskell:master Jun 25, 2016
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