-
-
Notifications
You must be signed in to change notification settings - Fork 371
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Proposal: remove install.hs script #2491
Comments
More context: I was trying to help clean up the stack yamls to reduce their maintenance cost and perceived drag on contributions. I think the stack yamls exist for these reasons:
I just learned about the install script, and had questions about it:
|
I think i somewhat responded to some questions in the issue description
not sure how could the install script build hls using stack underneath for a ghc version without a preexistent stack.yaml
not sure, maybe some users who are used to it from the days it was the unique way to install hls |
Ok, if nobody disagree a plan could be:
|
I'm using ./install.hs script quite regularly to build latest hls from master branch. |
Stack used to be the only supported way to build HIE (three years ago?) reliably, since the install instructions used to be quite elaborate. I dont remember details (back then I probably didn't understand them properly anyway). After we started supporting cabal, we were in a weird limbo, where you could use cabal to install HIE using stack. Once we finally fixed this slight monstrosity, stack-*.yaml remained as the official documentation of which GHC versions HIE supported. E.g. adding even an empty stack-8.10.2.yaml allowed you to install HIE with cabal using GHC 8.10.2. Only the version number mattered, not the contents of the yaml file. I had the opinion, it would be easier to maintain if we didn't hardcode the supported GHC versions in the install script but derive it from the existing stack.yaml files. The script was copied over to HLS pretty much unchanged, thus this remnant of using stack.yamls to discover supported GHC versions remained.
I occasionally use it, since it sets up the proper copied and symlinks. One-step solutions are nice.
While I like the one-line solution to install HLS and the wrapper, setting up all the correct paths (which makes it easier to override a specific HLS version and use it in your editor, afaict), I think we can retire it, assuming no one uses it anymore for anything mission critical. |
@jhrcek what does the script give you ? (excuse my ignorance). I wonder what alternatives there may be. Attempting to answer myself: the hls-install tool
|
PS my original interest in install/hls-install was that I proposed to rename stack-8.10.7.yaml to stack.yaml, instead of maintaining two stack yaml files that are (should be) identical (#2501). But this would cause problems for / require changes to install. If install is no longer needed, that extra stack yaml could be dropped. Beyond this I have not much opinion on install, except
|
Don't get me wrong, I'm not against removing the script. |
sure, there is a mention here: https://haskell-language-server.readthedocs.io/en/latest/installation.html#ghcup examples taken from
|
well it is documented in the official docs with detail as the main way to build hls from source: https://haskell-language-server.readthedocs.io/en/latest/installation.html#building
ghcup can build hls from source too and some use cases or workarounds needs building from source |
I knew there'd be more more docs somewhere. If the script remains, https://haskell-language-server.readthedocs.io/en/latest/installation.html#building could be made discoverable from install.hs and install/README.md. |
I guess ghcup can't build an arbitrary version of hls, eg an experimental branch ? |
ghcup can build any arbitrary hls version from any repo + commit: see @jhrcek have you got the chance to try ghcup to see if it can be used for your workflow? |
Yes, feel free to get rid of the install script. |
It got removed. |
cabal install
/stack install
to install hls and hls-wrapper and then make a copy as hls-${ghc-version}. It only hides the hls-wrapper looking for hls-${ghcVersion} machinery//cc @simonmichael @fendor as recently we discussed this in the irc channel
The text was updated successfully, but these errors were encountered: