unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#58512: Patch to make cperl-perldoc call perldoc case-insensitively
@ 2022-10-14 11:34 Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2022-10-14 12:36 ` Stefan Kangas
  2022-10-14 12:48 ` bug#58512: Closed by commit b175a9fb7ee Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
  0 siblings, 2 replies; 4+ messages in thread
From: Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2022-10-14 11:34 UTC (permalink / raw)
  To: 58512


[-- Attachment #1.1: Type: text/plain, Size: 292 bytes --]

The attached patch calls perldoc with -i, so it is case insensitive. This
is more convenient (the user doesn't have to get the case right), and works
like "man". I find this particularly useful for perl, as many modules and
functions have mixed case in their names.

-- 
https://rrt.sc3d.org

[-- Attachment #1.2: Type: text/html, Size: 627 bytes --]

[-- Attachment #2: 0001-Do-perl-documentation-lookups-case-insensitively-lik.patch --]
[-- Type: text/x-patch, Size: 883 bytes --]

From b175a9fb7eea49cdf8171821498f2c5efaaecd98 Mon Sep 17 00:00:00 2001
From: Reuben Thomas <rrt@sc3d.org>
Date: Fri, 14 Oct 2022 13:30:43 +0200
Subject: [PATCH] Do perl documentation lookups case-insensitively, like man

* lisp/progmodes/cperl-mode.el (cperl-perldoc): add -i to the perldoc
command.
---
 lisp/progmodes/cperl-mode.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/progmodes/cperl-mode.el b/lisp/progmodes/cperl-mode.el
index 20a73e238e9..539b2771490 100644
--- a/lisp/progmodes/cperl-mode.el
+++ b/lisp/progmodes/cperl-mode.el
@@ -8323,7 +8323,7 @@ cperl-perldoc
 				  'cperl-short-docs
 				  'variable-documentation))))
 	 (Man-switches "")
-	 (manual-program (if is-func "perldoc -f" "perldoc")))
+         (manual-program (concat "perldoc -i" (if is-func " -f"))))
     (Man-getpage-in-background word)))
 
 ;;;###autoload
-- 
2.34.1


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

* bug#58512: Patch to make cperl-perldoc call perldoc case-insensitively
  2022-10-14 11:34 bug#58512: Patch to make cperl-perldoc call perldoc case-insensitively Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
@ 2022-10-14 12:36 ` Stefan Kangas
  2022-10-14 12:45   ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2022-10-14 12:48 ` bug#58512: Closed by commit b175a9fb7ee Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
  1 sibling, 1 reply; 4+ messages in thread
From: Stefan Kangas @ 2022-10-14 12:36 UTC (permalink / raw)
  To: Reuben Thomas, 58512

Reuben Thomas via "Bug reports for GNU Emacs, the Swiss army knife of
text editors" <bug-gnu-emacs@gnu.org> writes:

> The attached patch calls perldoc with -i, so it is case insensitive. This
> is more convenient (the user doesn't have to get the case right), and works
> like "man". I find this particularly useful for perl, as many modules and
> functions have mixed case in their names.
>
> --
> https://rrt.sc3d.org
> From b175a9fb7eea49cdf8171821498f2c5efaaecd98 Mon Sep 17 00:00:00 2001
> From: Reuben Thomas <rrt@sc3d.org>
> Date: Fri, 14 Oct 2022 13:30:43 +0200
> Subject: [PATCH] Do perl documentation lookups case-insensitively, like man
>
> * lisp/progmodes/cperl-mode.el (cperl-perldoc): add -i to the perldoc
> command.
> ---
>  lisp/progmodes/cperl-mode.el | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/lisp/progmodes/cperl-mode.el b/lisp/progmodes/cperl-mode.el
> index 20a73e238e9..539b2771490 100644
> --- a/lisp/progmodes/cperl-mode.el
> +++ b/lisp/progmodes/cperl-mode.el
> @@ -8323,7 +8323,7 @@ cperl-perldoc
>  				  'cperl-short-docs
>  				  'variable-documentation))))
>  	 (Man-switches "")
> -	 (manual-program (if is-func "perldoc -f" "perldoc")))
> +         (manual-program (concat "perldoc -i" (if is-func " -f"))))
>      (Man-getpage-in-background word)))
>
>  ;;;###autoload
> --
> 2.34.1

LGTM.





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

* bug#58512: Patch to make cperl-perldoc call perldoc case-insensitively
  2022-10-14 12:36 ` Stefan Kangas
@ 2022-10-14 12:45   ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
  0 siblings, 0 replies; 4+ messages in thread
From: Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2022-10-14 12:45 UTC (permalink / raw)
  To: Stefan Kangas; +Cc: 58512

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

On Fri, 14 Oct 2022 at 14:36, Stefan Kangas <stefankangas@gmail.com> wrote:

>
> LGTM.
>

Thanks, for this simple patch I think I can take that as a positive review,
so I've pushed it.

-- 
https://rrt.sc3d.org

[-- Attachment #2: Type: text/html, Size: 774 bytes --]

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

* bug#58512: Closed by commit b175a9fb7ee
  2022-10-14 11:34 bug#58512: Patch to make cperl-perldoc call perldoc case-insensitively Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
  2022-10-14 12:36 ` Stefan Kangas
@ 2022-10-14 12:48 ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
  1 sibling, 0 replies; 4+ messages in thread
From: Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors @ 2022-10-14 12:48 UTC (permalink / raw)
  To: 58512-done

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



[-- Attachment #2: Type: text/html, Size: 26 bytes --]

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

end of thread, other threads:[~2022-10-14 12:48 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-10-14 11:34 bug#58512: Patch to make cperl-perldoc call perldoc case-insensitively Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-10-14 12:36 ` Stefan Kangas
2022-10-14 12:45   ` Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-10-14 12:48 ` bug#58512: Closed by commit b175a9fb7ee Reuben Thomas via Bug reports for GNU Emacs, the Swiss army knife of text editors

Code repositories for project(s) associated with this public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).