由于重复性错误,leiningen构建失败

时间:2012-09-30 08:07:06

标签: clojure leiningen

我已经和lein2一起工作了一段时间,它一直很好。然而今天麻烦开始了,无论我用lein2键入哪个命令,它都会给我以下错误。我尝试删除〜/ .m2,在这种情况下,它再次下载deps但最终给了我同样的错误。

我也试过删除并再次下载lein2。以下是它给出的错误 -

  

检查:依赖关系和:错别字的存储库。这有可能   指定的jar不在任何存储库中。如果是这样,请参阅“自由浮动   Jars“在http://j.mp/repeatability下无法解析依赖关系

无论项目或文件夹如何,都会发生错误。下面是我的〜/ .lein / profiles.clj -

{:user {:plugins [[lein-immutant "0.8.1"]
                  [lein-difftest "1.3.7"]
                  [lein-marginalia "0.7.1"]
                  [lein-pprint "1.1.1"]
                  [lein-swank "1.4.4"]
                  [lein-ring "0.7.5"]
                  [lein-cljsbuild "0.2.7"]
                  [lein-eclipse "1.0.0"]
                  [lein-git-deps "0.0.1-SNAPSHOT"]
                  [lein-outdated "0.1.0"]
                  [lein-noir "1.2.1"]
                  [lein-beanstalk "0.2.2"]
                  [lein-cloudbees "1.0.0"]
                  [lein-pedantic "0.0.3"]
                  [clj-ns-browser "1.3.0"]
                  [lein-ritz "0.4.2"]
                  [lein-midje "2.0.0-SNAPSHOT"]]}}

下面是project.clj文件 -

(defproject hs-2 "0.1.0-SNAPSHOT"
  :description "FIXME: write description"
  :url "http://example.com/FIXME"
  :license {:name "Eclipse Public License"
            :url "http://www.eclipse.org/legal/epl-v10.html"}
  :dependencies [[org.clojure/clojure "1.4.0"]
                 [net.cgrand/moustache "1.1.0" :exclusions [org.clojure/clojure]]
                 [enlive "1.0.1" :exclusions [org.clojure/clojure]]
                 [ring "1.1.5"]
                 [clj-time "0.4.4"]
                 [clj-http "0.5.3"]
                 [org.thnetos/cd-client "0.3.4" :exclusions [[org.clojure/clojure] cheshire]]
                 [clojurewerkz/urly "1.0.0"]
                 [clj-airbrake "2.0.0"]]
  :profiles {:dev {:dependencies [[ring-serve "0.1.2"]
                                  [ring-mock "0.1.3"]
                                  [ritz/ritz-debugger "0.4.2"]
                                  [ritz/ritz-repl-utils "0.4.2"]
                                  [midje "1.4.0" :exclusions [org.clojure/clojure]]]}}
  :ring {:handler hs-2.routes/my-app}
  :repl-options {:init-ns hs-2.core
                 :init (do
                         (use 'hs-2.routes)
                         (use 'ring.util.serve)
                         (serve my-app)
                         (use 'ring.mock.request)
                         )}
  :resource-paths ["resources/public"]
  :pedantic :warn)

1 个答案:

答案 0 :(得分:5)

这是因为您正在使用SNAPSHOT依赖项。在shell或export LEIN_SNAPSHOTS_IN_RELEASE=1脚本中设置lein以覆盖此内容。