Skip to content

Separate out Stack.Setup to its own package #4261

Open
@snoyberg

Description

@snoyberg

First, the general arguments back and forth: this is generally useful functionality, which can be easier to maintain as a separate package with a stable API Stack depends on. Downside: it takes work to separate it out, and maintaining changes between two packages is harder than one.

Now, specifically for this module: I have a use case (a dev environment for my kids, https://twitter.com/snoyberg/status/1032948626815901697) where I'd like to be able to write a tool that has no system dependencies and relies on a GHC installation. Currently, I have it depending on Stack being available, but it would be nice to not depend on Stack's availability.

Further, once this is separated out, I think there are some major improvements that can be made to how Stack installs and manages GHC installations, such as:

  • Have a config file pointing to various GHC installations, making it easy to provide your own
  • Provide an option to install GHC in a system-wide location

Maintaining this outside the confines of Stack should make it much easier to make such major improvements.

If there are no objections, I'll implement this myself in the coming week, with the kids IDE as a test case to demonstrate that it's working for both Stack and another application. I'll separate out the code into a package inside subs (still thinking of a name, ideas welcome).

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions