Skip to content

Commit

Permalink
Added :checkout-deps-shares option
Browse files Browse the repository at this point in the history
Used to specify other directories added to the classpath from the checked out projects.
  • Loading branch information
paraseba committed Jul 5, 2011
1 parent 81ba0dd commit 0681d1f
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
7 changes: 7 additions & 0 deletions sample.project.clj
Expand Up @@ -69,6 +69,13 @@
;; 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
;; 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]
Expand Down
4 changes: 2 additions & 2 deletions src/leiningen/classpath.clj
Expand Up @@ -25,8 +25,8 @@
;; Note that this resets the leiningen.core/project var!
:let [proj (read-dependency-project dep)]
:when proj]
(for [d [:source-path :compile-path :resources-path]]
(ensure-absolute (proj d) dep)))))
(for [d (:checkout-deps-shares project [:source-path :compile-path :resources-path])]
(ensure-absolute (d proj) dep)))))

(defn user-plugins []
(for [jar (.listFiles (file (leiningen-home) "plugins"))
Expand Down

0 comments on commit 0681d1f

Please sign in to comment.