haskell-ide-engine
haskell-ide-engine copied to clipboard
Should we provide a means to generate a multi-cradle file?
As I understand it, a multi-cradle hie.yaml maps from files to components in the cabal file.
This can be done in a mechanical way, that will be correct 95% of the time.
Perhaps we should provide a code action etc to do this. Possibly triggered when the hie-bios is not able to load a given file.
e.g. if the hie.yaml
is
cradle: {stack: {component: "ghcide:lib"}}
and the user opens the file exe/Main.hs
, this fails, but perhaps we need a code action to generate a cradle like
cradle:
stack:
- path: "./src/"
component: "ghcide:lib"
- path: "./exe/Main.hs"
component: "ghcide:exe"
(hand made example, may not work).