 (defn- check-packages
   "Check the packages found at the given key in the project map.
    Will check the given repository urls for metadata."
-  [repos packages]
+  [repos packages settings]
   (let [retrieve! (partial retrieve-metadata! repos)]
     (doseq [{:keys [group-id artifact-id version] :as dep} 
             (map dependency-map packages)]
       (when-let [mta (retrieve! group-id artifact-id)]
-        (when-let [latest (latest-version mta)]
+        (when-let [latest (latest-version mta settings)]
           (when (version-outdated? version latest)
             (println
               (str "[" (:dependency-str dep) " \"" (:version-str latest) "\"]")

  [v]
  (= (:qualifier v) "snapshot"))

(defn latest-version
  "Get map of the latest available version in the given metadata XML
   string."
  [mta]
  (->> (version-seq mta)
    (map version-map)
    (filter (complement snapshot?))
    (sort version-map-compare)
    (last)))

;; ## Project Map Inspection


      :author "Yannick Scherer"}
  leiningen.ancient
  (:require [leiningen.core.project :as project :only [defaults]]
            [clojure.data.xml :as xml :only [parse-str]]
            [clojure.tools.cli :as cli :only [cli]]))

;; ## Utility Functions

