Skip to content

--only-dependencies #2

Closed
Closed

Description

@DanBurton

Installing only dependencies is my main use case for this tool, and I'd love to see it work.

$ stk install --only-dependencies
cabal: unrecognized 'fetch' option `--only-dependencies'
stackage-install: readProcess: cabal "fetch" "--dry-run" "--only-dependencies" (exit 1): failed
$ cabal --version
cabal-install version 1.20.0.3

(I tried this on Windows with minghc-7.8.4.)

Activity

  1. cocreature commented on May 2, 2015

    @cocreature

    This seems like a more general problem. Passing -j also doesn't work. I guess the problem is that everything is passed to cabal fetch instead of cabal install.

  2. cocreature commented on May 2, 2015

    @cocreature

    Looking at the code the arguments are passed to cabal fetch as well as to cabal install. I think there needs to be some way to specify arguments that are passed to only one of them.

  3. snoyberg commented on May 2, 2015

    @snoyberg
    Contributor

    Sorry about that, I had it (mostly) right the first time. I've added a fix and pushed to Hackage, together with the following explanation in the README:

    The output from cabal install --dry-run doesn't actually give us information on which packages need to be downloaded, only the packages to be installed. This will be different in the case of local packages. Unfortunately, cabal fetch won't work for us either, since it accepts different arguments see #2. The compromise we have now is to just continue working in the presence of errors during download, though a more robust solution would be to check if one of the arguments refers to a local package.

    Can you confirm that it works now?

  4. cocreature commented on May 2, 2015

    @cocreature

    I confirm that it's working. (Looks like I can't close the issue as I didn't create it)

  5. snoyberg commented on May 2, 2015

    @snoyberg
    Contributor

    Cool, thanks for checking so quickly!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions