quicklisp-client icon indicating copy to clipboard operation
quicklisp-client copied to clipboard

Install depends-on without loading system

Open fisxoj opened this issue 8 years ago • 3 comments

In the exciting, new world of docker, it's a good idea to cache intermediate steps of generating a disk image. In python, for example, that means copying the requirements.txt into the docker image and then running pip install -r requirements.txt to pull down the python modules needed.

For common lisp, it would be nice to be able to do the same thing. I can do this programmatically with

(ql:quickload (asdf:system-depends-on (asdf:find-system :mgl)))

if I wanted to load mgl's dependencies. It would be nice and convenient to do it with a single command, though!

One could imagine doing something like

(ql:quickload :mgl :dependencies-only t)

But I thought about that for all of three seconds and there's probably a better name.

fisxoj avatar Jun 15 '16 16:06 fisxoj

You could do something like this:

(in-package :ql-dist-user)
(map nil 'ensure-installed (flatten (dependency-tree "mgl")))

It's not as terse as a new option to quickload, but it works today.

quicklisp avatar Jun 15 '16 19:06 quicklisp

Neat! Is that better than the version with asdf in some way?

Feel free to mark as an enhancement or close as you like. It just seemed like there might be a real use case for this, so I figured I'd ask.

On Wed, Jun 15, 2016, 3:31 PM Zach Beane [email protected] wrote:

You could do something like this:

(in-package :ql-dist-user) (map nil 'ensure-installed (flatten (dependency-tree "mgl")))

It's not as terse as a new option to quickload, but it works today.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/quicklisp/quicklisp-client/issues/134#issuecomment-226295024, or mute the thread https://github.com/notifications/unsubscribe/ABdb2uWU5eA16lktaxRyVuetbhvLT4f3ks5qMFMpgaJpZM4I2iuq .

fisxoj avatar Jun 15 '16 19:06 fisxoj

In my experience, ASDF systems sometimes have implicit dependencies that only become apparent when loading them. Quicklisp's system database explicitly includes them.

quicklisp avatar Jun 15 '16 19:06 quicklisp