Skip to content
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

Output the reason why package/module was installed #732

Open
wclr opened this issue Jan 16, 2021 · 2 comments
Open

Output the reason why package/module was installed #732

wclr opened this issue Jan 16, 2021 · 2 comments
Assignees

Comments

@wclr
Copy link
Contributor

wclr commented Jan 16, 2021

There should be a way to know why a package/module was installed (downloaded) showing which packages depend on it.

We could add an argument to spago ls deps , so e.g. if you want to know all the transitive dependencies of halogen you'd do spago ls deps --transitive halogen

In other package managers there is API called why for example yarn why package-name.

@f-f
Copy link
Member

f-f commented Oct 14, 2023

We can get this in after #1069

@f-f f-f added the blocked label Oct 14, 2023
@f-f
Copy link
Member

f-f commented Oct 15, 2023

Thinking about the design of this:

We would support both modules and packages under the same command (we can distinguish easily because modules are capitalised, packages can't be:

spago explain Data.Maybe

spago explain aff

The result could look something like this:

$ spago explain maybe
{
  "module": "Data.Maybe",
  "package": "maybe",
  "dependents": [
    {
      "module": "Data.List",
      "package": "lists",
      "dependents": [
        {
          "module": "Main",
          "package": "my-project"
        }
      ]
    }
  ]
}

@f-f f-f added this to the spago-next beta bugs milestone Dec 10, 2023
@f-f f-f removed the blocked label Dec 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants