dramforever/vscode-ghc-simple

A way to ignore a file from being checked

mystaroll opened this issue · 2 comments

Thank you for providing such a useful extension.
Currently, all viewed files are loaded into ghci. An issue with this is that the first failing load prevents the other ones from reporting their errors.

For example, I am using -dth-dec-file to dump some info in .hs files which I am viewing while I am writing other code, the extension fails on those files before checking my actual code.

It would be nice to have an option for ignoring certain files to be checked (for example, an option that takes a glob pattern, or a list of filenames).
Thanks

Sorry for the extremely delayed response. I've recently started working on supporting multi-component/multi-package projects. I think your issue might be helped by this.

Specifically, files not listed as a source file should be ignored if set up correctly.

If you haven't abandoned vscode-ghc-simple, please consider testing out development versions of the vgs-bios branch. See more information in the discussion here: #87.

In short, you will need to install a development version of the vgs-bios branch and set up an hie.yaml file, with the same format as the one accepted by hie-bios to tell vscode-ghc-simple about your project structure. If you need help or find any problems please do consider reaching out.

Not everything is well-supported yet, but hopefully simple multi-component or multi-package setups will work. The same file should also help out those who use ghcide. Many projects already have an hie.yaml file, so these will hopefully work out of the box. See the discussion page linked above for details for more information.

Thanks for considering helping out!

Released in v0.2.0