Skip to content

Commit

Permalink
Search for pom.xml in jar's dirname, not only target. fix #8
Browse files Browse the repository at this point in the history
Keeps us backwards compatible with Leiningen 1.7.0.
  • Loading branch information
ato committed Mar 15, 2012
1 parent 695b6e9 commit ed51bae
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/leiningen/push.clj
Expand Up @@ -71,11 +71,13 @@
(JSch/setLogger (proxy [Logger] []
(isEnabled [level] true)
(log [level message] (println level message)))))
(let [jarfile (get-jar-filename project)]
(let [jarfile (get-jar-filename project)
targetpath (.getParentFile (io/file jarfile))
pomfile (io/file targetpath "pom.xml")]
(pom project)
(jar project)
(try
(scp-send repo "target/pom.xml" jarfile)
(scp-send repo pomfile jarfile)
(catch JSchException e
(.printStackTrace e)
(when (= (.getMessage e) "Auth fail")
Expand All @@ -86,4 +88,4 @@
"work yet with DSA or passphrased keys. I'm working\n"
"on fixing this. You can also push directly with scp:\n\n"
"lein pom\n"
"scp pom.xml " jarfile " clojars@clojars.org:" )))))))
"scp " pomfile " " jarfile " clojars@clojars.org:" )))))))

0 comments on commit ed51bae

Please sign in to comment.