NixOS / mvn2nix-maven-plugin

Generate project-info.json for use with nix's Maven repository generation functions
MIT License
31 stars 21 forks source link

URLs have // and result in 404 #10

Closed yurrriq closed 7 years ago

yurrriq commented 7 years ago

When using this on a Clojure project I had to do the following after generating project-info.json:

sed -i 's|\(maven2/\)/|\1/|g'          project-info.json
sed -i 's|\(clojars\.org/repo\)/|\1|g' project-info.json
yurrriq commented 7 years ago

N.B. This may be an issue with build-maven instead. I'm using this version.

shlevy commented 7 years ago

Can you share an example of a project spec with a bad URL?

yurrriq commented 7 years ago

Sure, I'll make a minimal failing example. It could also be a problem with lein pom.

yurrriq commented 7 years ago

Ok, so the problem arose when I patched my project.clj to add :local-repo "home/.m2/repo" and didn't use the hacked java from lein-nix-build. That works for leiningen, but not for maven. I'll submit a patch to lein-nix-build instead. Thanks for inspiring me to look into it further. :smile:

charles-dyfis-net commented 5 years ago

I encountered this without :local-repo in use, but with a <repository><url> with a trailing / in the path.

We may just want to prune those characters where present.