From 60a8ed82d659f0eadc3771cc2fdfbd99bee0ade6 Mon Sep 17 00:00:00 2001 From: Phil Hagelberg Date: Tue, 5 Jul 2011 20:29:35 -0700 Subject: [PATCH] Clarify :checkout-deps-shares in sample.project.clj. --- sample.project.clj | 15 ++++++++------- src/leiningen/classpath.clj | 4 +++- 2 files changed, 11 insertions(+), 8 deletions(-) diff --git a/sample.project.clj b/sample.project.clj index 84df9561b..2d1a4bdf1 100644 --- a/sample.project.clj +++ b/sample.project.clj @@ -69,13 +69,14 @@ ;; use a regex that will be matched against filenames in the project root. ;; Defaults to #"^$NAME-.*\.jar$". :regex-to-clean #"hs_err_pid.*" - ;; Load dependencies from checkouts/ directory. Set this to be a vector of - ;; functions that take the target project as argument. - ;; The default is [:source-path :compile-path :resources-path] - ;; but you could also add, for instance, :test-path to share tests, or - ;; ~(fn [p] (str (:root p) "/lib/dev/*")) to load also development dependencies - ;; from the checked out project (Java 1.6+) - :checkout-deps-shares + ;; Paths to include on the classpath from each project in the + ;; checkouts/ directory. (See the FAQ in the Readme for more details + ;; about checkout dependencies.) Set this to be a vector of + ;; functions that take the target project as argument. Defaults to + ;; [:source-path :compile-path :resources-path], but you could use + ;; the following to share code from the test suite: + :checkout-deps-shares [:source-path :test-path + ~(fn [p] (str (:root p) "/lib/dev/*"))] ;; Load these namespaces on startup to pick up hooks from them. Hooks ;; generally come from plugins, but may be included in your project source. :hooks [leiningen.hooks.difftest] diff --git a/src/leiningen/classpath.clj b/src/leiningen/classpath.clj index 84c10aa1e..5d902d06f 100644 --- a/src/leiningen/classpath.clj +++ b/src/leiningen/classpath.clj @@ -25,7 +25,9 @@ ;; Note that this resets the leiningen.core/project var! :let [proj (read-dependency-project dep)] :when proj] - (for [d (:checkout-deps-shares project [:source-path :compile-path :resources-path])] + (for [d (:checkout-deps-shares project [:source-path + :compile-path + :resources-path])] (ensure-absolute (d proj) dep))))) (defn user-plugins []