emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] emacs-26 16a529e 1/4: Remove upload functionality of packa


From: Noam Postavsky
Subject: [Emacs-diffs] emacs-26 16a529e 1/4: Remove upload functionality of package-x from the elisp manual
Date: Thu, 25 Jul 2019 18:36:23 -0400 (EDT)

branch: emacs-26
commit 16a529e215331626f66160194701b74248cb9fa5
Author: Stefan Kangas <address@hidden>
Commit: Noam Postavsky <address@hidden>

    Remove upload functionality of package-x from the elisp manual
    
    Suggested by Stefan Monnier.
    Ref: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=19537#8
    
    * doc/lispref/package.texi (Package Archives): Don't document
    package-x upload functions in the elisp manual, since they are not
    very commonly used.  (Bug#19537)
    * lisp/emacs-lisp/package-x.el (package-archive-upload-base)
    (package-upload-buffer, package-upload-file): Add to the doc strings
    any details removed from the elisp manual that would otherwise be
    missing.
---
 doc/lispref/package.texi     | 35 -----------------------------------
 lisp/emacs-lisp/package-x.el | 13 +++++++++++--
 2 files changed, 11 insertions(+), 37 deletions(-)

diff --git a/doc/lispref/package.texi b/doc/lispref/package.texi
index 39bdc01..8729f02 100644
--- a/doc/lispref/package.texi
+++ b/doc/lispref/package.texi
@@ -307,41 +307,6 @@ How to accomplish this is beyond the scope of this manual.
 by default; type @kbd{M-x load-library @key{RET} package-x @key{RET}} to
 load it, or add @code{(require 'package-x)} to your init file.
 @xref{Lisp Libraries,, Lisp Libraries, emacs, The GNU Emacs Manual}.
-Once loaded, you can make use of the following:
-
-@defopt package-archive-upload-base
-The value of this variable is the base location of a package archive,
-as a directory name.  The commands in the @code{package-x} library
-will use this base location.
-
-The directory name should be absolute.  You may specify a remote name,
-such as @file{/ssh:foo@@example.com:/var/www/packages/}, if the
-package archive is on a different machine.  @xref{Remote Files,,
-Remote Files, emacs, The GNU Emacs Manual}.
-@end defopt
-
-@deffn Command package-upload-file filename
-This command prompts for @var{filename}, a file name, and uploads that
-file to @code{package-archive-upload-base}.  The file must be either a
-simple package (a @file{.el} file) or a multi-file package (a
-@file{.tar} file); otherwise, an error is raised.  The package
-attributes are automatically extracted, and the archive's contents
-list is updated with this information.
-
-If @code{package-archive-upload-base} does not specify a valid
-directory, the function prompts interactively for one.  If the
-directory does not exist, it is created.  The directory need not have
-any initial contents (i.e., you can use this command to populate an
-initially empty archive).
-@end deffn
-
-@deffn Command package-upload-buffer
-This command is similar to @code{package-upload-file}, but instead of
-prompting for a package file, it uploads the contents of the current
-buffer.  The current buffer must be visiting a simple package (a
-@file{.el} file) or a multi-file package (a @file{.tar} file);
-otherwise, an error is raised.
-@end deffn
 
 @noindent
 After you create an archive, remember that it is not accessible in the
diff --git a/lisp/emacs-lisp/package-x.el b/lisp/emacs-lisp/package-x.el
index a207ece..9e63dce 100644
--- a/lisp/emacs-lisp/package-x.el
+++ b/lisp/emacs-lisp/package-x.el
@@ -47,6 +47,8 @@
 
 (defcustom package-archive-upload-base "/path/to/archive"
   "The base location of the archive to which packages are uploaded.
+The commands in the package-x library will use this as base
+location.
 This should be an absolute directory name.  If the archive is on
 another machine, you may specify a remote name in the usual way,
 e.g. \"/ssh:address@hidden:/var/www/packages/\".
@@ -273,7 +275,9 @@ if it exists."
 (defun package-upload-buffer ()
   "Upload the current buffer as a single-file Emacs Lisp package.
 If `package-archive-upload-base' does not specify a valid upload
-destination, prompt for one."
+destination, prompt for one.
+Signal an error if the current buffer is not visiting a simple
+package (a \".el\" file)."
   (interactive)
   (save-excursion
     (save-restriction
@@ -286,8 +290,13 @@ destination, prompt for one."
 Interactively, prompt for FILE.  The package is considered a
 single-file package if FILE ends in \".el\", and a multi-file
 package if FILE ends in \".tar\".
+Automatically extract package attributes and update the archive's
+contents list with this information.
 If `package-archive-upload-base' does not specify a valid upload
-destination, prompt for one."
+destination, prompt for one.  If the directory does not exist, it
+is created.  The directory need not have any initial contents
+\(i.e., you can use this command to populate an initially empty
+archive)."
   (interactive "fPackage file name: ")
   (with-temp-buffer
     (insert-file-contents file)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]