Skip to content

Conversation

@GuillaumedeVolpiano
Copy link
Member

@hololeap : I was thinking of adding a possibility to use revdep-scanner with random-rebuild, to check that everything goes fine when we bump versions on a widely used package (looking at you, dev-haskell/data-default). And I was thinking that rather than running the executable, it might be better to use the core functions, so I separated your code between executable and library.

I see that my fixers went a little wild on Main.hs, so if it's of interest, I'll redo the Main.hs part in a cleaner way.

@hololeap
Copy link
Member

I had been considering splitting Main.hs up for a while, though I was only going to add the new modules to the executable under other-modules (I didn't see the need to expose them as a library.)

Which parts of revdep-scanner did you want exposed so they could be used in random-build?

@GuillaumedeVolpiano
Copy link
Member Author

GuillaumedeVolpiano commented Apr 12, 2025

This is the line I have
import RevdepScanner (ConstraintMap,
MatchMode (Matching, NonMatching),
argsR, lookupResults, parseAll)

Actually probably only need MatchMode(Matching).

If it's too much of a bother, I can also add a similar process in GHRB/IO/Utils.hs. An issue we're going to face is to have cabal behave nicely with a library that would be installed locally but that is not on hackage. I'm not sure how to add it to a cabal file without a cabal project.

@hololeap
Copy link
Member

An issue we're going to face is to have cabal behave nicely with a library that would be installed locally but that is not on hackage. I'm not sure how to add it to a cabal file without a cabal project.

You can do this with source-repository-package in cabal.project. The ebuild should have no trouble with this since it will just look for any matching packages installed on the system.

@GuillaumedeVolpiano
Copy link
Member Author

Right. My issue was with the ebuild actually l I'd sorted it out exactly as you recommended. It's running now, still some things to tweak but it works.

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