* lisp/emacs-lisp/package-x.el (package-upload-buffer-internal): Pass
`extras' slot from `package-desc' to `package-make-ac-desc'. * lisp/emacs-lisp/package.el (package-desc-from-define): Accept additional arguments as plist, convert it to an alist and store it in the `extras' slot. (package-generate-description-file): Convert extras alist back to plist and append to the `define-package' form arguments. (package--alist-to-plist): New function. (package--ac-desc): Add `extras' slot. (package--add-to-archive-contents): Check if the archive-contents vector is long enough, and if it is, pass its `extras' slot value to `package-desc-create'. (package-buffer-info): Call `lm-homepage', pass the returned value to `package-desc-from-define'. (describe-package-1): Render the homepage button. * test/automated/package-test.el (simple-single-desc-1-4): Remove, it was unused. (simple-single-desc): Expect :homepage property. (multi-file-desc): Same. (with-package-test): Do not save previous `default-directory' value, let-bind the var instead. (package-test-install-single): Expect :homepage property in the generated pkg file. (package-test-describe-package): Expect Homepage button. (package-test-describe-non-installed-package) (package-test-describe-non-installed-multi-file-package): Same. (package-test-describe-not-installed-package): Remove, it was a duplicate. * test/automated/package-x-test.el (package-x-test--single-archive-entry-1-3): Expect :homepage property. (package-x-test--single-archive-entry-1-4): Expect nil extras slot. * test/automated/data/package/archive-contents: Add :homepage properties to `simple-single' and `multi-file'. * test/automated/data/package/simple-single-1.3.el: Add URL header. Fixes: debbugs:13291
This commit is contained in:
parent
832966e57f
commit
056453c62e
9 changed files with 122 additions and 52 deletions
|
@ -209,6 +209,7 @@ if it exists."
|
|||
(pcase file-type
|
||||
(`single (lm-commentary))
|
||||
(`tar nil))) ;; FIXME: Get it from the README file.
|
||||
(extras (package-desc-extras pkg-desc))
|
||||
(pkg-version (package-version-join split-version))
|
||||
(pkg-buffer (current-buffer)))
|
||||
|
||||
|
@ -217,7 +218,7 @@ if it exists."
|
|||
(let ((contents (or (package--archive-contents-from-url archive-url)
|
||||
(package--archive-contents-from-file)))
|
||||
(new-desc (package-make-ac-desc
|
||||
split-version requires desc file-type)))
|
||||
split-version requires desc file-type extras)))
|
||||
(if (> (car contents) package-archive-version)
|
||||
(error "Unrecognized archive version %d" (car contents)))
|
||||
(let ((elt (assq pkg-name (cdr contents))))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue