Fork me on GitHub
#tools-deps
<
2019-02-01
>
misha13:02:20

is there good bare-bones template for clojure+clojurescript monorepo with tools.deps?

dominicm18:02:15

Edge isn't quite bare bones, but is the only thing I know of without having looked much

misha00:02:15

reading through the docs now, thanks

misha13:02:00

{:deps {com.bhauman/figwheel-main       {:mvn/version "0.2.0"}}
opieop

eraad19:02:21

Hi! I’m trying to use this library (originally built with Leiningen) from a clojure-cli project: https://github.com/datil/xmldsig I added a deps.edn but I have a couple of questions: 1. The lib has a src/main/java source folder. Do I need to add this as a “src” folder in the deps.edn? 2. I’m trying to import it using git deps, it adds to the classpath but I cannot seem to be able to import it. Any recommendations on where to look?

hiredman19:02:31

you won't be able to use it

alexmiller19:02:39

libraries with Java source can’t be used this way

alexmiller19:02:51

clj is designed for libs with no “build” step

matthias06:02:48

This is going to be game changing too - we're applying the idea in some really interesting ways.

dominicm06:02:59

Can you share more about how you're able to leverage this to great effect?

alexmiller19:02:07

which is most Clojure libraries, but not those with Java source

alexmiller19:02:40

you can use the built version as an artifact via Maven or via a locally built jar by pointing to it with a :local/root coordinate

eraad20:02:03

Cool @alexmiller @hiredman thanks!

viesti21:02:22

if gen-class would work at the repl, wouldn’t this mean a build-free support of libs using gen-class? 🙂

viesti21:02:30

don’t know how many those would be though

dominicm21:02:49

@viesti you have conflicting files in the class path, nothing can save you now. The ordering is pretty much random, oz is working by coincidence.

dominicm21:02:32

Fwiw, you could resolve this if you are a bit crazy by iterating over all of the matches.

viesti21:02:41

yeah, the moment when you realise that the floor starts moving

dominicm21:02:23

I'd recommend that public/index.html isn't used, and that a namespaced prefix is used instead.

viesti21:02:15

hum, that might be it

viesti21:02:33

since might be difficult to fish out the conflicting dependency

dominicm22:02:24

The other library, json-to-html should also not use public/index.html

viesti22:02:05

yeah, could point this out to the other lib

viesti22:02:25

makes me think on using public/index.html in my own apps… 🙂

dominicm22:02:59

You should only use it there !

viesti22:02:12

yeah, should report to the other dep actually, I think

viesti22:02:20

seems that markdown-to-hiccup-0.6.1.jar might have unnecessary resources in it’s artifact

dominicm22:02:13

It's both really. Unless oz is an app.

viesti22:02:13

spend the day pulling a hairball of Ansible dependencies, now wondering how I ended up to another ball of strings in the evening

viesti22:02:32

thinking I’m good at catching balls of strings

dominicm06:02:55

I've only learned this stuff from getting tangled too

dominicm06:02:09

Some of us are destined for tangling

dominicm06:02:39

now figwheel main doesn't work...

viesti07:02:06

The case of the creeping index.html... Trying to hold off thoughts of hijacking webapps by malicious classpath resource injection 🙀

dominicm07:02:10

a lot of people unknowingly serve a /license.html as part of jetty iirc

dominicm07:02:36

oh, no, it's an about.html

dominicm07:02:44

I found out when I discovered the page on our site

viesti10:02:09

heh, there really is such a resource, didn’t find it from served from couple of our apps

dominicm16:02:28

Depends how you set it up, some setups serve html from the root :)

viesti17:02:08

yup, duct template has nice default, which creates a folder with the app name for the resources

viesti22:02:20

probably both, although oz is higher in the hierarchy, but it can be a dependency itself

viesti23:02:22

almost forgot, thanks for the advice! :)