[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
scratch/package-vc-fixes 3dc2ec3fce 21/48: Make documentation building f
From: |
Philip Kaludercic |
Subject: |
scratch/package-vc-fixes 3dc2ec3fce 21/48: Make documentation building for source packages more robust |
Date: |
Wed, 16 Nov 2022 04:50:00 -0500 (EST) |
branch: scratch/package-vc-fixes
commit 3dc2ec3fceee618c12f2ec27f24fe46cb15000cb
Author: Philip Kaludercic <philipk@posteo.net>
Commit: Philip Kaludercic <philipk@posteo.net>
Make documentation building for source packages more robust
* lisp/emacs-lisp/package-vc.el (package-vc--build-documentation): Log
output and display error messages if anything goes wrong.
---
lisp/emacs-lisp/package-vc.el | 22 ++++++++++++++--------
1 file changed, 14 insertions(+), 8 deletions(-)
diff --git a/lisp/emacs-lisp/package-vc.el b/lisp/emacs-lisp/package-vc.el
index 55daa48e3e..a50f7fbda9 100644
--- a/lisp/emacs-lisp/package-vc.el
+++ b/lisp/emacs-lisp/package-vc.el
@@ -353,10 +353,8 @@ asynchronously."
FILE can be an Org file, indicated by its \".org\" extension,
otherwise it's assumed to be an Info file."
(let* ((pkg-name (package-desc-name pkg-desc))
- (pkg-dir (package-desc-dir pkg-desc))
- (output (file-name-concat
- (format "%s.info" pkg-name)
- pkg-dir)))
+ (default-directory (package-desc-dir pkg-desc))
+ (output (expand-file-name (format "%s.info" pkg-name))))
(when (string-match-p "\\.org\\'" file)
(require 'ox)
(require 'ox-texinfo)
@@ -364,10 +362,18 @@ otherwise it's assumed to be an Info file."
(insert-file-contents file)
(setq file (make-temp-file "ox-texinfo-"))
(org-export-to-file 'texinfo file)))
- (call-process "makeinfo" nil nil nil
- "--no-split" file "-o" output)
- (call-process "install-info" nil nil nil
- output pkg-dir)))
+ (with-current-buffer (get-buffer-create " *package-vc doc*")
+ (erase-buffer)
+ (cond
+ ((/= 0 (call-process "makeinfo" nil t nil
+ "--no-split" file "-o" output))
+ (message "Failed to build manual %s, see buffer %S"
+ file (buffer-name)))
+ ((/= 0 (call-process "install-info" nil t nil
+ output (expand-file-name "dir")))
+ (message "Failed to install manual %s, see buffer %S"
+ output (buffer-name)))
+ ((kill-buffer))))))
(defun package-vc--unpack-1 (pkg-desc pkg-dir)
"Prepare PKG-DESC that is already checked-out in PKG-DIR.
- scratch/package-vc-fixes 2e007c62f3 14/48: Track 'default-directory' while updating source packages, (continued)
- scratch/package-vc-fixes 2e007c62f3 14/48: Track 'default-directory' while updating source packages, Philip Kaludercic, 2022/11/16
- scratch/package-vc-fixes 3046447102 22/48: ; Assert that 'package-lisp-dir' is used with real packages, Philip Kaludercic, 2022/11/16
- scratch/package-vc-fixes 78830856bc 28/48: Rename 'package-vc-refresh' to 'package-vc-rebuild', Philip Kaludercic, 2022/11/16
- scratch/package-vc-fixes 2024a01fdc 30/48: Mention package name when package is lacking VC data, Philip Kaludercic, 2022/11/16
- scratch/package-vc-fixes 6080b169f3 47/48: Avoid duplicate source packages in 'package-alist', Philip Kaludercic, 2022/11/16
- scratch/package-vc-fixes 9bbfdbba24 06/48: Mark 'package-vc-update' as interactive, Philip Kaludercic, 2022/11/16
- scratch/package-vc-fixes e8043ebc57 03/48: Rename '-ensure-packages' to -install-selected-packages', Philip Kaludercic, 2022/11/16
- scratch/package-vc-fixes 155c3673d7 13/48: Allow specifying a :lisp-dir for package descriptions, Philip Kaludercic, 2022/11/16
- scratch/package-vc-fixes 4b0a5e30b9 16/48: Fix type error in package-vc prompt function, Philip Kaludercic, 2022/11/16
- scratch/package-vc-fixes 7ee6f3e32d 20/48: Fix 'package-vc-install-selected-packages' recursive load, Philip Kaludercic, 2022/11/16
- scratch/package-vc-fixes 3dc2ec3fce 21/48: Make documentation building for source packages more robust,
Philip Kaludercic <=
- scratch/package-vc-fixes 692edc9e72 26/48: Have 'package-vc-selected-packages' consider all installed packages, Philip Kaludercic, 2022/11/16
- scratch/package-vc-fixes 1a3b38f8b9 41/48: Remove duplicate package descriptions after updating, Philip Kaludercic, 2022/11/16
- scratch/package-vc-fixes d744f988f3 42/48: Only fetch elpa-packages.eld when necessary, Philip Kaludercic, 2022/11/16
- scratch/package-vc-fixes b8f6ce839a 43/48: Allow the direct installation of package specifications, Philip Kaludercic, 2022/11/16
- scratch/package-vc-fixes 18ee1e728a 48/48: Ensure 'package-vc-prepare-patch' runs in the right directory, Philip Kaludercic, 2022/11/16