mirror of
https://github.com/correl/melpa.git
synced 2024-11-22 03:00:11 +00:00
Preserve keyword info like :url in upstream -pkg.el files (fixes #2594)
This commit is contained in:
parent
ce1dc6807f
commit
e9bce98c7e
1 changed files with 16 additions and 2 deletions
|
@ -748,7 +748,20 @@ Optionally PRETTY-PRINT the data."
|
|||
(let ((package-def (pb/read-from-file file-path)))
|
||||
(if (eq 'define-package (car package-def))
|
||||
(let* ((pkgfile-info (cdr package-def))
|
||||
(descr (nth 2 pkgfile-info)))
|
||||
(descr (nth 2 pkgfile-info))
|
||||
(rest-plist (subseq pkgfile-info 4))
|
||||
(extras (let (alist)
|
||||
(while rest-plist
|
||||
(unless (memq (car rest-plist) '(:kind :archive))
|
||||
(let ((value (cadr rest-plist)))
|
||||
(when value
|
||||
(push (cons (car rest-plist)
|
||||
(if (eq (car-safe value) 'quote)
|
||||
(cadr value)
|
||||
value))
|
||||
alist))))
|
||||
(setq rest-plist (cddr rest-plist)))
|
||||
alist)))
|
||||
(when (string-match "[\r\n]" descr)
|
||||
(error "Illegal multi-line package description in %s" file-path))
|
||||
(vector
|
||||
|
@ -758,7 +771,8 @@ Optionally PRETTY-PRINT the data."
|
|||
(list (car elt) (version-to-list (cadr elt))))
|
||||
(eval (nth 3 pkgfile-info)))
|
||||
descr
|
||||
(nth 1 pkgfile-info)))
|
||||
(nth 1 pkgfile-info)
|
||||
extras))
|
||||
(error "No define-package found in %s" file-path)))))
|
||||
|
||||
(defun pb/merge-package-info (pkg-info name version)
|
||||
|
|
Loading…
Reference in a new issue