GNU bug report logs - #61552
Feature request: Add variable Man-prefer-synchronous-call

Previous Next

Package: emacs;

Reported by: Sebastian Tennant <sdt <at> sebyte.me>

Date: Thu, 16 Feb 2023 16:14:01 UTC

Severity: wishlist

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #11 received at 61552 <at> debbugs.gnu.org (full text, mbox):

From: Sebastian Tennant <sdt <at> sebyte.me>
To: 61552 <at> debbugs.gnu.org
Subject: Re: bug#61552: Feature request: Add variable
 Man-prefer-synchronous-call
Date: Mon, 20 Feb 2023 18:11:17 +0000
[Message part 1 (text/plain, inline)]
Quoth Basil Contovounesios <contovob <at> tcd.ie>
on Thu, 16 Feb 2023 17:09:27 +0000:
> […]
> Please attach the patches here so that they can be tracked in this
> bugtracker.
>
> Thanks,

No problem Basil.  Here's a patch against master:

[0001-Add-user-customizable-variable-Man-prefer-synchronou.patch (text/x-diff, inline)]
From 179af66f885630a7bdf3d3f3146aceb8ad205ce6 Mon Sep 17 00:00:00 2001
From: Sebastian Tennant <sdt <at> sebyte.me>
Date: Thu, 10 Mar 2022 08:36:04 +0000
Subject: [PATCH] Add user-customizable variable Man-prefer-synchronous-call

* lisp/man.el (Man-getpage-in-background): Only call #'start-process
when 'make-process satisfies #'fboundp AND Man-prefer-synchronous-call
is bound to nil.
---
 lisp/man.el | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/lisp/man.el b/lisp/man.el
index 286edf9314e..fb4f8f02db7 100644
--- a/lisp/man.el
+++ b/lisp/man.el
@@ -97,6 +97,12 @@ man
   :group 'external
   :group 'help)
 
+(defcustom Man-prefer-synchronous-call nil
+  "Non-nil means always call the Un*x man command synchronously,
+rather than asynchronously, which is the default behaviour."
+  :type 'boolean
+  :group 'man)
+
 (defcustom Man-filter-list nil
   "Manpage cleaning filter command phrases.
 This variable contains a list of the following form:
@@ -1118,7 +1124,8 @@ Man-getpage-in-background
 					"[cleaning...]")
 				      'face 'mode-line-emphasis)))
 	(Man-start-calling
-	 (if (fboundp 'make-process)
+	 (if (and (fboundp 'make-process)
+                  (not Man-prefer-synchronous-call))
 	     (let ((proc (start-process
 			  manual-program buffer
 			  (if (memq system-type '(cygwin windows-nt))
-- 
2.30.2


This bug report was last modified 2 years and 75 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.