Merge pull request #277455 from Vonfry/melpa/update-fix

update-melpa: try to fix some compatiblility issues on cl-lib and url-retrive.
This commit is contained in:
Peder Bergebakken Sundt 2024-02-10 12:28:18 +01:00 committed by GitHub
commit 3c5b9e6af5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -6,7 +6,7 @@
(require 'semaphore-promise)
(require 'url)
(require 'json)
(require 'cl)
(require 'cl-lib)
(require 'subr-x)
(require 'seq)
@ -77,7 +77,7 @@ return Promise to resolve in that process."
(defun parse-previous-archive (filename)
(let ((idx (make-hash-table :test 'equal)))
(loop for desc in
(cl-loop for desc in
(let ((json-object-type 'hash-table)
(json-array-type 'list)
(json-key-type 'symbol))
@ -166,7 +166,7 @@ return Promise to resolve in that process."
(defun recipe-info (recipe-index ename)
(if-let (desc (gethash ename recipe-index))
(destructuring-bind (rcp-commit . rcp-sha256) desc
(cl-destructuring-bind (rcp-commit . rcp-sha256) desc
`((commit . ,rcp-commit)
(sha256 . ,rcp-sha256)))
`((error . "No recipe info"))))
@ -204,7 +204,7 @@ return Promise to resolve in that process."
(seq-let [recipe-index unstable-sha stable-sha] res
(append `((ename . ,ename))
(if-let (desc (gethash ename recipe-index))
(destructuring-bind (rcp-commit . rcp-sha256) desc
(cl-destructuring-bind (rcp-commit . rcp-sha256) desc
(append `((commit . ,rcp-commit)
(sha256 . ,rcp-sha256))
(when (not unstable-aprops)
@ -257,10 +257,9 @@ return Promise to resolve in that process."
url (lambda (status)
(funcall resolve (condition-case err
(progn
(goto-char (point-min))
(search-forward "\n\n")
(url-http-parse-headers)
(goto-char url-http-end-of-headers)
(message (buffer-substring (point-min) (point)))
(delete-region (point-min) (point))
(funcall parser))
(funcall reject err))))))))