all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#37546: 26.3; Implement multi-file package README long description generation as described by elisp manual
@ 2019-09-29  3:52 Bruno Félix Rezende Ribeiro
  2019-09-30 17:35 ` Stefan Kangas
  0 siblings, 1 reply; 5+ messages in thread
From: Bruno Félix Rezende Ribeiro @ 2019-09-29  3:52 UTC (permalink / raw)
  To: 37546

[-- Attachment #1: Type: text/plain, Size: 631 bytes --]

Hello Emacs developers,

The inlined patch implements the (already expected) generation of
multi-file package long description from a potential README file
residing inside the package’s content directory.  Currently Emacs only
implements the long description generation from commentary sections and
for single-file packages.

This behavior is documented in ‘(elisp) Multi-file Packages’ and the
function ‘package-upload-buffer-internal’ from ‘package-x.el’ had a
‘FIXME: Get it from the README file.’ right on the spot of this
implementation.


Let me know if any change is necessary.  Thanks!



[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: package-x-multi-file-README-long-description.patch --]
[-- Type: text/x-diff, Size: 748 bytes --]

diff --git a/lisp/emacs-lisp/package-x.el b/lisp/emacs-lisp/package-x.el
index 2815be3..d929cf5 100644
--- a/lisp/emacs-lisp/package-x.el
+++ b/lisp/emacs-lisp/package-x.el
@@ -205,7 +205,10 @@ if it exists."
 	       (commentary
                 (pcase file-type
                   ('single (lm-commentary))
-                  ('tar nil))) ;; FIXME: Get it from the README file.
+                  ('tar (when (file-exists-p "README")
+                          (with-temp-buffer
+                            (insert-file-contents "README")
+                            (buffer-string))))))
                (extras (package-desc-extras pkg-desc))
 	       (pkg-version (package-version-join split-version))
 	       (pkg-buffer (current-buffer)))

[-- Attachment #3: Type: text/plain, Size: 259 bytes --]



-- 
 88888  FFFFF Bruno Félix Rezende Ribeiro (oitofelix) [0x28D618AF]
 8   8  F     http://oitofelix.freeshell.org/
 88888  FFFF  mailto:oitofelix@gnu.org
 8   8  F     irc://chat.freenode.org/oitofelix
 88888  F     xmpp://oitofelix@riseup.net


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-01-23 22:21 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-09-29  3:52 bug#37546: 26.3; Implement multi-file package README long description generation as described by elisp manual Bruno Félix Rezende Ribeiro
2019-09-30 17:35 ` Stefan Kangas
2019-10-02  1:56   ` Bruno Félix Rezende Ribeiro
2019-10-02  9:31     ` Stefan Kangas
2020-01-23 22:21     ` Stefan Kangas

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.