Fork me on GitHub
#tools-deps
<
2018-12-10
>
Brendan van der Es14:12:20

Hi all, question: Suppose I'm in a REPL in the middle of a datomic session with large cache in memory and I need to pull in a new library to continue processing. Is 'add-lib' the only way to pull in this dependency without losing the in-memory state of the jvm session? In other words, is there any way to have the CLI preserve this session state in memory in between reboots for new deps? Assuming the answer to this is a negative and suppose 'add-lib' fails, any other ways to preserve datomic memory cache between repl reboots?

Ben Hammond15:12:00

I know its probably too late for this repl session ...

alexmiller14:12:39

probably a better question for #datomic but afaik, the answer is no

Brendan van der Es14:12:28

Yea, was afraid of that. I'm exploring ideas for a more datomic-centric repl experience but would need to make this kind of reloading seamless. Thanks for the quick response; will try #datomic.

jeremys15:12:52

Hello, did someone try to install clojure with nix on os x? I am not using homebrew atm and I was wondering if the clojure package from nix included the necessary stuff to run tools deps and cli

alexmiller15:12:53

don’t know - it’s not built or maintained by the core team

dominicm15:12:21

@jeremys I don't know package it is, but one of them does include tools deps.

jeremys15:12:03

I am thinking it fetches the necessary tools, I was about to take a look at the brew formulae to get a sense where things might differ but the tool part of the url on clojure’s website and the deps mention in the nix package leads me to think it’s there. Thx.

alexmiller15:12:17

seems fine. that’s a couple versions back but what it does is intentionally pretty dumb.

jeremys15:12:48

I’ll take a look! thank you.

jeremys16:12:42

Just for information the nix package comes with the tools deps machinery.

rschmukler22:12:16

Hey all 🙂 . Is it possible to use my deps.edn to point to a github repo that is using a leiningen project.clj? I naively tried pointing at it but got hit with an error regarding detecting the manifest. Makes sense, and I realize it might be out of the scope of what tools.deps is trying to achieve... but also feels quite useful

seancorfield22:12:01

tools.deps, which is what does the dependency resolution under the hood, doesn't know how to use a project.clj file. Perhaps open an issue against that repo and see if they'll add a deps.edn file?

alexmiller22:12:27

or if it has no transitive deps, you can force it to be a deps.edn project by putting :deps/manifest :deps in the coordinate

seancorfield22:12:10

Presumably, you could do that anyway and just add that project's deps to your own deps.edn file anyway @alexmiller?

alexmiller22:12:31

yes, that should work

rschmukler22:12:41

Thanks for the quick replies! Sadly, it's of almost no value but for its transitive dependencies (which I needed to update). I ended up just excluding its (outdated) dependencies and then manually updating the dependencies in my deps.edn

rschmukler22:12:04

Thanks again for the fast responses