Closed nixant closed 3 years ago
@nixant Let's make it so that the version number (8.8.4
) has to be a suffix but it should contain ghc
somewhere in the directory. That should work for your case, right?
@MondayMorningHaskell yes that would work for my case. We can also check that ghc is prefix and version number is suffix, this will cover the current case as well.
@nixant Sorry took me a while to get to this, but here's a PR if you want to take a look!
Thanks for fixing it.
NoGhcError is thrown when ghc is not installed.
The code looks for the directory ghc-version (ghc-8.8.4), but in some cases the name of the folder where stack installs ghc can be different, e.g ghc-tinfo6-8.8.4 in my case.
One solution seems to replace the predicate for find here: https://github.com/MondayMorningHaskell/haskellings/blob/fafadd5bbb722b54c1b7b114e34dc9b96bb7ca4d/src/Config.hs#L190 to (isSuffixOf ghcVersionNumber)