Coder Social home page Coder Social logo

Comments (3)

fendor avatar fendor commented on September 2, 2024 1

The easiest way is to write a stack-hls.yaml file that contains the options that you want and tell HLS to use that.

I can think of two solutions / workarounds:

  1. Provide the STACK_YAML variable to HLS only https://github.com/haskell/vscode-haskell?tab=readme-ov-file#set-additional-environment-variables-for-the-server
  2. Provide the stackYaml key in hie.yaml (https://hackage.haskell.org/package/hie-bios-0.14.0/#stack) and tell git to ignore changes, for example via git update-index --assume-unchanged hie.yaml.

I open a file in the editor and HLS starts building, but the build flags have changed so it starts over

I believe, this happens because HLS tells stack to use our custom compiler, which invalidates the caches. You can provide a different work-dir, this should avoid cache invalidation: https://docs.haskellstack.org/en/stable/environment_variables/#stack_work

from haskell-language-server.

fendor avatar fendor commented on September 2, 2024 1

Ill consider this issue resolved, feel free to open a new issue, if you want to propose a new feature :)

from haskell-language-server.

ChrisPenner avatar ChrisPenner commented on September 2, 2024

@fendor ah great, this gives me something to work with! A bit annoying that I need to copy the whole stack.yaml and keep that up to date though 😢 ; but I'll give this a try 🙌🏼

from haskell-language-server.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.