Don't invoke release plugin fallback unless external plugin is present.
The existing fallback logic assumes that the presence of two release tasks on the classpath can only be due to one of them coming from a plugin, but this is not true; you can have an uberjar of Leiningen building Leiningen itself. Fixes #2198
This commit is contained in:
parent
77ad686ff8
commit
3ac76a3ccd
1 changed files with 4 additions and 2 deletions
|
@ -138,5 +138,7 @@ bump. If none is given, it defaults to :patch."
|
|||
(when-let [[resource] (-> (.getContextClassLoader (Thread/currentThread))
|
||||
(.getResources "leiningen/release.clj")
|
||||
(enumeration-seq) (distinct) (rest) (seq))]
|
||||
(clojure.lang.Compiler/load (io/reader resource)
|
||||
"leiningen/release.clj" (str resource)))
|
||||
(let [release-str (str resource)]
|
||||
(when-not (re-find #"support existing release plugin" release-str)
|
||||
(clojure.lang.Compiler/load (io/reader resource)
|
||||
"leiningen/release.clj" release-str))))
|
||||
|
|
Loading…
Reference in a new issue