Commit 7794d692 authored by Eric Timmons's avatar Eric Timmons
Browse files

Compute release archive name locally

Avoids an issue fetching from gitlab API
parent a4c646e8
......@@ -141,27 +141,21 @@
:ensure-directory t))
(defun url-filename (url)
"Return the filename of ~url~."
(file-namestring (puri:uri-path url)))
(defun url-location (url)
"Return a list of two elements. First is the ~url~ to fetch the file, the
second is the filename of the file located at ~url~."
(if (listp url)
(values (first url) (second url))
(values url (url-filename url))))
(defun release-cache-pathname (release)
`(,(source-archive-cache (release-source release))
,(uiop:strcat (project-name (release-project release))
(release-version release)
(defun ensure-tarball-fetched (release)
"Ensure that the files needed to install ~release~ have been downloaded."
(let ((version-url (tarball-release/url release)))
(multiple-value-bind (url filename)
(url-location version-url)
(let ((archive-pathname (merge-pathnames filename
(source-archive-cache (release-source release)))))
(ensure-file-fetched archive-pathname url
:hint :immutable)
(let ((version-url (tarball-release/url release))
(archive-pathname (release-cache-pathname release)))
(ensure-file-fetched archive-pathname version-url
:hint :immutable)
(defmethod install-release ((release tarball-release))
(let* ((version-string (release-version release))
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