1 parent 5a501e0 commit 1e8ad3fCopy full SHA for 1e8ad3f
1 file changed
ql-https.lisp
@@ -59,11 +59,15 @@
59
(apply #'fetcher url file args)))))
60
61
(defun url-to-release (url)
62
- "extracts name of release from URL"
63
- (when (search "/archive/" url)
64
- (let* ((start (+ (search "/archive/" url) (length "/archive/")))
65
- (end (position #\/ url :start start)))
66
- (subseq url start end))))
+ "obtains name of release from URL"
+ (let* ((http-url (if (string-equal "https" (subseq url 0 5))
+ (uiop:strcat "http" (subseq url 5))
+ url))
+ (all-releases (ql-dist:provided-releases t))
67
+ (release (find http-url all-releases
68
+ :test #'string=
69
+ :key #'ql-dist:archive-url)))
70
+ (ql-dist:project-name release)))
71
72
#+sbcl
73
(defun md5 (file)
0 commit comments