如何配置leiningen的maven用法? [英] How to configure leiningen's maven usage?
问题描述
我的问题是leiningen没有在我的电脑上工作。我收到以下错误:
My problem is that leiningen is not working on my computer. I get errors like these:
Could not transfer artifact lein-ring:lein-ring:pom:0.4.5 from/to central (http://repo1.maven.org/maven2): Connection to http://repo1.maven.org r
Could not transfer artifact lein-ring:lein-ring:pom:0.4.5 from/to clojars (https://clojars.org/repo/): Connection to https://clojars.org refused
我认为问题是我有一个镜像配置在我的maven安装的settings.xml。我如何告诉leiningen使用嵌入的maven或一些其他maven安装没有自定义配置?
I think the problem is that I have a mirror configured in my settings.xml of my maven installation. How can I tell leiningen to use an embedded maven or some other maven installation which does not have custom configuration?
我使用maven为其他java项目,
I'm using maven for other java projects and it conflicts somehow with leiningen.
推荐答案
您可以向 project.clj
或者,在这种情况下,可能更好的〜/ .lein / profiles.clj
You can add mirror definitions to project.clj
or, probably better in this case, to ~/.lein/profiles.clj
但这里是关键位:
:mirrors {"central" {:name "Ibiblio"
:url "http://mirrors.ibiblio.org/pub/mirrors/maven2"}
#"clojars" {:name "Internal nexus"
:url "http://mvn.local/nexus/releases"
:repo-manager true}}
这篇关于如何配置leiningen的maven用法?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!