Fork me on GitHub
#beginners
<
2015-08-25
>
escherize15:08:44

I have a beginnerish question: I am having trouble with a not-popular library that I want to use very much.

escherize15:08:06

I can meta-dot into library jar itself, and edit the code and recompile

escherize15:08:25

Is that good practice? Is there a better approach

shaun-mahood17:08:01

@escherize: Do you have access to the source code?

escherize17:08:19

I do, it's in the jar, and on github.

escherize17:08:00

the good news is I've figured out what I was doing wrong in that instance. But i'm still curious about the optimal approach to investigating external library code

escherize17:08:19

I need to rave about the library too, it's so great. It's called Skyscraper

shaun-mahood17:08:45

I've found it pretty easy to build from the source code, rename and include the modified version using leiningen

escherize17:08:58

what's the workflow around that, @shaun-mahood ?

shaun-mahood17:08:22

Let me just double check and I'll let you know what I did

shaun-mahood17:08:53

Using skyscraper as an example, grab the source code and open project.clj. Change defproject skyscraper "0.1.1" to (defproject skyscraper "0.1.1-mine" or something else unique. Then do lein install from within the skyscraper folder and it should install to your local lein repo. You can then refer to it in another lein project.clj by adding [skyscraper "0.1.1-mine"] as a dependency

escherize17:08:44

wow that's really slick.

shaun-mahood17:08:17

Yeah. When I saw you talking about jar files I got kind of scared.

shaun-mahood17:08:32

But then I know nothing about java, so jar files are about the scariest part of clojure for me. simple_smile