Commit d1a35cb8 authored by Eric Timmons's avatar Eric Timmons
Browse files

Add resolve-requirement for project requirements

parent 028a509f
......@@ -483,16 +483,16 @@ objects to a list of system-releases."))
(mapcar (rcurry #'cons t)
(release/system-files vcs-release)))))))
;; (defmethod resolve-requirement ((req project-requirement) sources)
;; (let* ((project-name (requirement/name req))
;; (version-spec (requirement/version-spec req))
;; (project (find-project-in-sources project-name sources))
;; (releases (project/releases project))
;; (applicable-releases (remove-if-not (rcurry #'release-satisfies-version-spec-p version-spec)
;; releases)))
;; (mapcar (lambda (x)
;; (cons x (release/system-releases x)))
;; (sort applicable-releases #'release->))))
(defmethod resolve-requirement ((req project-requirement) search-state)
(let* ((project-name (requirement/name req))
(version-spec (requirement/version-spec req))
(project (find-project-in-sources project-name))
(releases (project/releases project))
(applicable-releases (remove-if-not (rcurry #'release-satisfies-version-spec-p version-spec)
releases)))
(mapcar (lambda (x)
(list x :system-releases (release/system-releases x)))
(sort applicable-releases #'release->))))
(defmethod resolve-requirement ((req system-requirement) search-state)
(let* ((system-name (requirement/name req))
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment