Reputation: 10353
I have an application in a sandbox. Cabal dependencies have no constraints so cabal install --only-dependencies
gives me the latest packages.
After a certain period of time I want to bump my dependencies to the latest versions but before this I want to see which dependencies are actually changed to a newer version.
I can check all of them manually of course. But I'd rather see a nice list of the things that will be upgraded.
I assume that cabal install --upgrade-dependencies --only-dependencies --dry-run
is the way to do it. I would expect it to give me the list of all the packages that are at newer version that the one in my sandbox. But it never works! I mean, it just says that all dependencies are up to date when they are clearly not. Am I doing something wrong or missing/misunderstanding something?
If I destroy my sandbox completely, rerun cabal install --only-dependencies
and diff the freeze files then I can see which packages got bumped. But this is silly. So how can I get cabal install --upgrade-dependencies --only-dependencies --dry-run
to work correctly and print all the packages that are going to be upgraded without blowing the sandbox? Ad if those options do not work in cabal why aren't they just removed to avoid confusion?
Thank you.
Upvotes: 3
Views: 356
Reputation: 729
You can use cabal list --installed
and compare "Default available version" with "Installed versions".
Unfortunately cabal's --simple-output
switch does not include that information, so to automate it you will need a smallish script.
Upvotes: 1