Re: ripgrep author seems happy with groff_man_style(7)

2024-11-02 Thread onf
Hi Branden, On Sat Oct 26, 2024 at 3:33 AM CEST, G. Branden Robinson wrote: > At 2024-10-25T16:51:26+0200, onf wrote: > > I wonder if the author tried Drew DeVault's scdoc, it seems to work > > well for simpler manpages. (Output is man.) > > I'm not crazy about the non-idiomatic section titles or

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread G. Branden Robinson
Hi Alex, At 2024-11-02T11:39:37+0100, Alejandro Colomar wrote: > And diffs are a real win for text. Thus, semantic newlines are a real > win for text. "Write poems, not prose." (Any chance we may get that > warning added to groff(1)? :D) Yes, but I've kicked it out to groff 1.25 because a gif

Re: Comparison against backslash obtained via .substring

2024-11-02 Thread G. Branden Robinson
Hi onf, At 2024-11-03T03:56:23+0100, onf wrote: > On Sun Nov 3, 2024 at 2:53 AM CET, onf wrote: > > changing the escape character hasn't occured to me, that's clever! > > Unfortunately it doesn't work -- groff won't allow me to set the > > escape character to a control one, and I cannot use some o

Re: Comparison against backslash obtained via .substring

2024-11-02 Thread G. Branden Robinson
Hi onf, At 2024-11-03T03:25:01+0100, onf wrote: > On Sat Nov 2, 2024 at 4:15 AM CET, Dave Kemper wrote: > > Parsing strings that contain escapes is something that an open groff > > bug report (http://savannah.gnu.org/bugs/?62264) seeks to make more > > consistent. Does the mechanism proposed in t

Re: Comparison against backslash obtained via .substring

2024-11-02 Thread onf
On Sun Nov 3, 2024 at 2:53 AM CET, onf wrote: > changing the escape character hasn't occured to me, that's clever! > Unfortunately it doesn't work -- groff won't allow me to set the > escape character to a control one, and I cannot use some obscure > unicode glyph because it must be ASCII... I coul

Re: Comparison against backslash obtained via .substring

2024-11-02 Thread G. Branden Robinson
Hi onf, At 2024-11-03T02:53:14+0100, onf wrote: > changing the escape character hasn't occured to me, that's clever! > Unfortunately it doesn't work -- groff won't allow me to set the > escape character to a control one, It does, but it has to be a valid input character. groff(7): On a ma

Re: Comparison against backslash obtained via .substring

2024-11-02 Thread onf
Hi Dave, On Sat Nov 2, 2024 at 4:15 AM CET, Dave Kemper wrote: > Parsing strings that contain escapes is something that an open groff > bug report (http://savannah.gnu.org/bugs/?62264) seeks to make more > consistent. Does the mechanism proposed in that report sound like it > would solve the prob

Re: Comparison against backslash obtained via .substring

2024-11-02 Thread onf
Hi Branden, On Sat Nov 2, 2024 at 10:16 AM CET, G. Branden Robinson wrote: > There's an example of this in groff's "an.tmac" file. > > It's not a model of elegance, but it works. > > https://git.savannah.gnu.org/cgit/groff.git/tree/tmac/an.tmac?id=5011cd1d5a647d977f74ccaad21e5abe004fe30e#n529 > >

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread Colin Watson
On Sat, Nov 02, 2024 at 07:50:23PM -0500, G. Branden Robinson wrote: > At 2024-11-02T19:06:53+, Colin Watson wrote: > > How embarrassing. Could somebody please file a bug on > > https://gitlab.com/man-db/man-db/-/issues to remind me to fix that? > > Done;

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread Alejandro Colomar
Hi Colin, On Sun, Nov 03, 2024 at 12:47:23AM +, Colin Watson wrote: > I'm not trying to stop you committing whatever you want to your > repository, of course, but I want to be clear that this doesn't actually > solve the right problem for manual page indexing. The point of the > parsing code

Re: [PATCH v2 1/3] scripts/bash_aliases: man_lsfunc(), man_lsvar(): Use mansect(1)

2024-11-02 Thread Alejandro Colomar
D'oh. Ignore this thread, please. I'm a bit rusty with git-send-email(1), it seems. On Sun, Nov 03, 2024 at 02:16:47AM +0100, Alejandro Colomar wrote: > Remove the man_section() function, and call the mansect(1) program > instead. > > Signed-off-by: Alejandro Colomar > --- > scripts/bash_alia

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread Colin Watson
(now with some local vim macros fixed to stop accidentally corrupting the To: lines of some of my outgoing emails ...) On Sat, Nov 02, 2024 at 08:09:29PM -0500, G. Branden Robinson wrote: > At 2024-11-03T00:47:23+, Colin Watson wrote: > > and the fact that the NAME section has both semantic an

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread G. Branden Robinson
Hi Colin, At 2024-11-03T00:47:23+, Colin Watson wrote: > (That's leaving aside things like localized man pages, which I know > some folks on the groff list tend to sniff I can think of only one, the maintainer of a rival formatter. ;-) > at but I think they're important, Me too. I agree w

[PATCH v2 4/4] src/bin/mansect: Preprocess with preconv(1)

2024-11-02 Thread Alejandro Colomar
This doesn't process the pages in a significant way, and has the benefit that it writes the name of the pages in the output. Signed-off-by: Alejandro Colomar --- src/bin/mansect | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/bin/mansect b/src/bin/mansect index a13a6

[PATCH v2 2/3] scripts/bash_aliases: man_lsfunc(), man_lsvar(): Use pcre2grep(1) instead of pcregrep(1)

2024-11-02 Thread Alejandro Colomar
pcregrep(1) is obsolete. Signed-off-by: Alejandro Colomar --- scripts/bash_aliases | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/bash_aliases b/scripts/bash_aliases index 25425c389..98b466410 100644 --- a/scripts/bash_aliases +++ b/scripts/bash_aliases @@ -54,

[PATCH v2 3/4] scripts/bash_aliases: man_lsfunc(), man_lsvar(): Use pcre2grep(1) instead of pcregrep(1)

2024-11-02 Thread Alejandro Colomar
pcregrep(1) is obsolete. Signed-off-by: Alejandro Colomar --- scripts/bash_aliases | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/bash_aliases b/scripts/bash_aliases index 25425c389..98b466410 100644 --- a/scripts/bash_aliases +++ b/scripts/bash_aliases @@ -54,

[PATCH v2 1/3] scripts/bash_aliases: man_lsfunc(), man_lsvar(): Use mansect(1)

2024-11-02 Thread Alejandro Colomar
Remove the man_section() function, and call the mansect(1) program instead. Signed-off-by: Alejandro Colomar --- scripts/bash_aliases | 45 ++-- 1 file changed, 6 insertions(+), 39 deletions(-) diff --git a/scripts/bash_aliases b/scripts/bash_aliases inde

[PATCH v2 3/3] src/bin/mansect: Preprocess with preconv(1)

2024-11-02 Thread Alejandro Colomar
This doesn't process the pages in a significant way, and has the benefit that it writes the name of the pages in the output. Signed-off-by: Alejandro Colomar --- src/bin/mansect | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/bin/mansect b/src/bin/mansect index a13a6

[PATCH v2 2/4] scripts/bash_aliases: man_lsfunc(), man_lsvar(): Use mansect(1)

2024-11-02 Thread Alejandro Colomar
Remove the man_section() function, and call the mansect(1) program instead. Signed-off-by: Alejandro Colomar --- scripts/bash_aliases | 45 ++-- 1 file changed, 6 insertions(+), 39 deletions(-) diff --git a/scripts/bash_aliases b/scripts/bash_aliases inde

[PATCH v2 1/4] src/bin/mansect, mansect.1: Add program and its manual page

2024-11-02 Thread Alejandro Colomar
Cc: "G. Branden Robinson" Cc: Colin Watson Cc: Signed-off-by: Alejandro Colomar --- man/man1/mansect.1 | 61 ++ src/bin/mansect| 26 2 files changed, 87 insertions(+) create mode 100644 man/man1/mansect.1 create mode 100755

[PATCH v2 0/4] Add mansect(1)

2024-11-02 Thread Alejandro Colomar
Hi Colin, Branden, I've further optimized the script to be 3x faster, simpler and more robust. It now also prints the filename in the output, by calling preconv(1), which is necessary for doing the job that mandb(8) does (see patch 4/4). Cheers, Alex Alejandro Colomar (4): src/bin/mansect, ma

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread Colin Watson
I'm not trying to stop you committing whatever you want to your repository, of course, but I want to be clear that this doesn't actually solve the right problem for manual page indexing. The point of the parsing code in mandb(8) - and I'm not claiming that it's great code or the perfect design, ju

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread G. Branden Robinson
Hi Colin, At 2024-11-02T19:06:53+, Colin Watson wrote: > How embarrassing. Could somebody please file a bug on > https://gitlab.com/man-db/man-db/-/issues to remind me to fix that? Done; . > lexgrog(1) is a useful (if oddly-named, sorry) debuggi

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread Alejandro Colomar
[CC trimmed] Hi Colin, On Sun, Nov 03, 2024 at 12:24:54AM +, Colin Watson wrote: > On Sun, Nov 03, 2024 at 01:05:34AM +0100, Alejandro Colomar wrote: > > Are you sure? With a small tweak, I get the following comparison: > > > > alx@devuan:~/src/linux/man-pages/man-pages/main$ time lexgr

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread Colin Watson
On Sun, Nov 03, 2024 at 01:05:34AM +0100, Alejandro Colomar wrote: > Are you sure? With a small tweak, I get the following comparison: > > alx@devuan:~/src/linux/man-pages/man-pages/main$ time lexgrog man/*/* | > wc > lexgrog: can't resolve man7/groff_man.7 > 12475 99295 9

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread Alejandro Colomar
On Sun, Nov 03, 2024 at 01:05:42AM +0100, Alejandro Colomar wrote: > Hi Colin, > > On Sat, Nov 02, 2024 at 11:47:14PM +, Colin Watson wrote: > > On Sat, Nov 02, 2024 at 10:36:20PM +0100, Alejandro Colomar wrote: > > > This is quite naive, and will not work with pages that define their own > >

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread Alejandro Colomar
Hi Colin, On Sat, Nov 02, 2024 at 11:47:14PM +, Colin Watson wrote: > On Sat, Nov 02, 2024 at 10:36:20PM +0100, Alejandro Colomar wrote: > > This is quite naive, and will not work with pages that define their own > > stuff, since this script is not groff(1). But it should be as fast as > > is

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread Colin Watson
On Sat, Nov 02, 2024 at 10:36:20PM +0100, Alejandro Colomar wrote: > This is quite naive, and will not work with pages that define their own > stuff, since this script is not groff(1). But it should be as fast as > is possible, which is what Colin wants, is as simple as it can be (and > thus relat

Re: [PATCH] CONTRIBUTING.d/patches: Document new features alongside the features

2024-11-02 Thread Alejandro Colomar
Oops, this was sent by accident. :) On Sun, Nov 03, 2024 at 12:10:18AM +0100, Alejandro Colomar wrote: > Link: > Cc: Jiri Olsa > Cc: Günther Noack > Signed-off-by: Alejandro Colomar > --- > > [offlist] > > Hi Günther, Jiri, > > I've prepared a draft of thi

Re: [PATCH 1/3] signal.7: Better description for SIGFPE

2024-11-02 Thread Alejandro Colomar
Oops, this was sent by accident. On Sun, Nov 03, 2024 at 12:10:27AM +0100, Alejandro Colomar wrote: > From: Vincent Lefevre > > SIGFPE has comment "Floating-point exception", which corresponds to > the FPE acronym. But this is misleading as this signal may also be > generated by an integer divi

[PATCH 2/3] src/bin/mansect, mansect.1: Add program and its manual page

2024-11-02 Thread Alejandro Colomar
Cc: "G. Branden Robinson" Cc: Colin Watson Cc: Signed-off-by: Alejandro Colomar --- man/man1/mansect.1 | 61 ++ src/bin/mansect| 33 + 2 files changed, 94 insertions(+) create mode 100644 man/man1/mansect.1 create mode 1

[PATCH 3/3] scripts/bash_aliases: man_section(), man_lsfunc(), man_lsvar(): Use mansect(1)

2024-11-02 Thread Alejandro Colomar
Signed-off-by: Alejandro Colomar --- scripts/bash_aliases | 38 ++ 1 file changed, 6 insertions(+), 32 deletions(-) diff --git a/scripts/bash_aliases b/scripts/bash_aliases index e461707c8..0b0b5e08a 100644 --- a/scripts/bash_aliases +++ b/scripts/bash_aliases

[PATCH 1/3] signal.7: Better description for SIGFPE

2024-11-02 Thread Alejandro Colomar
From: Vincent Lefevre SIGFPE has comment "Floating-point exception", which corresponds to the FPE acronym. But this is misleading as this signal may also be generated by an integer division by 0. Change it to "Erroneous arithmetic operation" from POSIX. Note: the GNU C Library manual says "fata

[PATCH 0/3] Add mansect(1) program and manual page

2024-11-02 Thread Alejandro Colomar
Hi Branden, Colin, I'm proposing the addition of this program to the Linux man-pages repository, as a spin-off of the man_section() shell function that we already have. Eventually, we could move it to a separate repository, if it is more appropriate. Could you please review? (And also give any

[PATCH] CONTRIBUTING.d/patches: Document new features alongside the features

2024-11-02 Thread Alejandro Colomar
Link: Cc: Jiri Olsa Cc: Günther Noack Signed-off-by: Alejandro Colomar --- [offlist] Hi Günther, Jiri, I've prepared a draft of this contributing process that we talked about. I won't officially post it until the other situation (sponsoring) is resolved, but

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread Alejandro Colomar
Hi Branden, Colin, On Sat, Nov 02, 2024 at 11:40:13AM +0100, Alejandro Colomar wrote: > > I also of course have ideas for generalizing the feature, so that you > > can request any (sub)section by name, and, with a bit more ambition,[4] > > paragraph tags (`TP`) too. > > > > So you could do things

Re: PDFPIC: un-explaned warning

2024-11-02 Thread Deri
On Saturday, 2 November 2024 17:29:14 GMT Bjarni Ingi Gislason wrote: > My fix broke down when I used "gnu.xpm" after installing "perlmagick" (tip > from Deri). > > Fixed "tmac/pdfpic.tmac" in my repository, which is now without a warning > for both "gnu.pdf" and "gnu.xpm". I have just pushed

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread Colin Watson
On Sat, Nov 02, 2024 at 05:08:37AM -0500, G. Branden Robinson wrote: > On GNU/Linux systems, the only man page indexer I know of is Colin > Watson's man-db--specifically, its mandb(8) program. But it's nicely > designed so that the "topic and summary description extraction" task is > delegated to

Re: PDFPIC: un-explaned warning

2024-11-02 Thread Bjarni Ingi Gislason
On Fri, Nov 01, 2024 at 09:10:20PM +, Bjarni Ingi Gislason wrote: > On Tue, Oct 29, 2024 at 01:20:19AM +, Bjarni Ingi Gislason wrote: [...] > > .ll 10n > > .PDFPIC -I -\n[.l]u /home/bg/git/groff/doc/gnu.pdf > > .if r stuff .tm stuff is defined > > I have added a correction to "tmac/pdfpi

Re: [mom] pdfmom: avoid a warning with perl 5.40.0

2024-11-02 Thread Deri
On Friday, 25 October 2024 22:22:26 GMT Bjarni Ingi Gislason wrote: > For perl > > This is perl 5, version 40, subversion 0 (v5.40.0) built for > x86_64-linux-gnu-thread-multi > (with 43 registered patches, see perl -V for more detail) > > Copyright 1987-2024, Larry Wall > > the line > > us

Re: gropdf: warning when "mixed_pickles.pdf" is created

2024-11-02 Thread Deri
On Friday, 25 October 2024 22:20:16 GMT Bjarni Ingi Gislason wrote: > I assume that you do use a different (older) version of perl than I have > now. > > Using your change does not improve the compilation as > > a) gropdf: warning: './../doc/gnu.xpm' does not appear to be a pdf file > > an

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread Alejandro Colomar
Hi Branden, On Sat, Nov 02, 2024 at 05:08:37AM -0500, G. Branden Robinson wrote: > [adding Colin Watson to CC; and the groff list because I started musing] > > Hi Alex, > > At 2024-11-01T21:07:29+0100, Alejandro Colomar wrote: > > > > > -/proc/pid/fdinfo/ \- information about file descriptors >

Re: [PATCH v2 1/3] proc_pid_fdinfo.5: Reduce indent for most of the page

2024-11-02 Thread G. Branden Robinson
[adding Colin Watson to CC; and the groff list because I started musing] Hi Alex, At 2024-11-01T21:07:29+0100, Alejandro Colomar wrote: > > > > -/proc/pid/fdinfo/ \- information about file descriptors > > > > +.IR /proc/ pid /fdinfo " \- information about file descriptors" > > > > > > I wouldn't

Re: Comparison against backslash obtained via .substring

2024-11-02 Thread G. Branden Robinson
Hi onf & Dave, At 2024-11-01T22:15:58-0500, Dave Kemper wrote: > Parsing strings that contain escapes is something that an open groff > bug report (http://savannah.gnu.org/bugs/?62264) seeks to make more > consistent. Does the mechanism proposed in that report sound like it > would solve the prob