[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug #59622] [PATCH] grog/subs.pl: Ignore lines added in front of ".TH"
From: |
Bjarni Ingi Gislason |
Subject: |
[bug #59622] [PATCH] grog/subs.pl: Ignore lines added in front of ".TH" by "pod2man" |
Date: |
Fri, 4 Dec 2020 13:33:30 -0500 (EST) |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Firefox/78.0 |
URL:
<https://savannah.gnu.org/bugs/?59622>
Summary: [PATCH] grog/subs.pl: Ignore lines added in front of
".TH" by "pod2man"
Project: GNU troff
Submitted by: bjarniig
Submitted on: Fri 04 Dec 2020 06:33:28 PM UTC
Category: Core
Severity: 3 - Normal
Item Group: Incorrect behaviour
Status: None
Privacy: Public
Assigned to: None
Open/Closed: Open
Discussion Lock: Any
Planned Release: None
_______________________________________________________
Details:
>From 69de136e8f07ba85d4251f8a171d9c9274d159f3 Mon Sep 17 00:00:00 2001
From: Bjarni Ingi Gislason <bjarniig@rhi.hi.is>
Date: Fri, 4 Dec 2020 18:19:58 +0000
Subject: [PATCH] grog/subs.pl: Ignore lines added in front of ".TH" by
"pod2man"
groff/src/roff/grog/subs.pl: Ignore lines added in front of ".TH" by
the perl module "Pod::Man" (pod2man)
Fixes wrong results for manuals, that are made with the current
"pod2man" command.
See bug #55302 for the initial report.
Signed-off-by: Bjarni Ingi Gislason <bjarniig@rhi.hi.is>
---
src/roff/grog/subs.pl | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/src/roff/grog/subs.pl b/src/roff/grog/subs.pl
index 65108e38..65e55e78 100644
--- a/src/roff/grog/subs.pl
+++ b/src/roff/grog/subs.pl
@@ -567,6 +567,11 @@ sub do_line {
return if ( $line =~ /^\.$/ ); # ignore .
return if ( $line =~ /^\.\.$/ ); # ignore ..
+ # Ignore "Standard preamble" from the perl module "Pod::Man" (pod2man)
+ return if ( $line =~ /^\.[[:lower:]]/ );
+ return if ( $line =~ /^\.\s*\\}/ );
+ return if ( $line =~ /^\.IX / );
+
if ( $before_first_command ) { # so far without 1st command
if ( $line =~ /^\.TH/ ) {
# check if .TH is 1st command for man
--
2.29.2
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?59622>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [bug #59622] [PATCH] grog/subs.pl: Ignore lines added in front of ".TH" by "pod2man",
Bjarni Ingi Gislason <=