nwolverson / purescript-language-server

MIT License
184 stars 41 forks source link

Provide release bundle #135

Closed arrowd closed 2 years ago

arrowd commented 3 years ago

After upgrading the package set and trying building purescript-language-server I get:

Error 1 of 2:

  in module PscIde.Server
  at .spago/psc-ide/v17.0.0/src/PscIde/Server.purs:18:1 - 18:24 (line 18, column 1 - line 18, column 24)

    Module Global was not found.
    Make sure the source file exists, and that it has been provided as an input to the compiler.

  See https://github.com/purescript/documentation/blob/master/errors/ModuleNotFound.md for more information,
  or to contribute content related to this error.

Error 2 of 2:

  in module IdePurescript.PscIdeServer
  at src/IdePurescript/PscIdeServer.purs:22:1 - 22:24 (line 22, column 1 - line 22, column 24)

    Module Global was not found.
    Make sure the source file exists, and that it has been provided as an input to the compiler.

  See https://github.com/purescript/documentation/blob/master/errors/ModuleNotFound.md for more information,
  or to contribute content related to this error.

This seems to be because https://github.com/purescript-deprecated/purescript-globals is deprecated.

nwolverson commented 3 years ago

This repo isn't updated to 0.14.1 just yet. However it supports 0.14.1 projects just fine, you can build it with the devDependency version of purescript in package.json and the specified package set.

arrowd commented 3 years ago

I want to package this project for FreeBSD and it requires compiling it from source. We have a PureScript package, but it is 0.14.1 already.

nwolverson commented 3 years ago

Right, thanks for context.

arrowd commented 3 years ago

Alternatively, if you provide a compiled script with node shebang in the releases section, the packaging would become dead simple.

nwolverson commented 3 years ago

The project now builds with PureScript 0.14.x. Additionally I added a JS bundle to the release uploads, which is to say the PureScript output is bundled - there are npm dependencies, so I'm not sure how useful or not this is.

arrowd commented 3 years ago

Yeah, external JS dependencies are pain to package. Would it be possible to include all dependencies too in the release tarball?

nwolverson commented 3 years ago

Update - I did try back at that time to bundle the dependencies and ran into some issues, I'll have another run at it at some point

nwolverson commented 2 years ago

This is now done, the single file release JS bundle is provided in releases, including bundling npm dependencies.

From https://github.com/nwolverson/purescript-language-server/releases/tag/v0.15.6

arrowd commented 2 years ago

Awesome, this is much appreciated! I have created a FreeBSD Port, so now FreeBSD users can install it with simple pkg install purescript-language-server.