[Bug 331561] Examples cut-n-pasted from man pages fail because of quotes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Please do not reply directly to this email. All additional
comments should be made in the comments box of this bug report.

Summary: Examples cut-n-pasted from man pages fail because of quotes


https://bugzilla.redhat.com/show_bug.cgi?id=331561


jpazdziora@xxxxxxxxxx changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jpazdziora@xxxxxxxxxx




------- Additional Comments From jpazdziora@xxxxxxxxxx  2007-10-15 04:44 EST -------
The problem is that if you have a POD document with a simple apostroph (\047),
when you convert it to man page, that apostrophe gets changed to \342\200\231.

$ cat test.pod 

=head1 Test

Testing

        perl -le 'print 1'

End of testing

$ od -c test.pod
0000000  \n   =   h   e   a   d   1       T   e   s   t  \n  \n   T   e
0000020   s   t   i   n   g  \n  \n  \t   p   e   r   l       -   l   e
0000040       '   p   r   i   n   t       1   '  \n  \n   E   n   d    
0000060   o   f       t   e   s   t   i   n   g  \n  \n
0000074
$ perldoc test.pod | od -c
0000000   T   E   S   T   (   1   )                                    
0000020                           U   s   e   r       C   o   n   t   r
0000040   i   b   u   t   e   d       P   e   r   l       D   o   c   u
0000060   m   e   n   t   a   t   i   o   n                            
0000100                               T   E   S   T   (   1   )  \n  \n
0000120  \n  \n   T  \b   T   e  \b   e   s  \b   s   t  \b   t  \n    
0000140                           T   e   s   t   i   n   g  \n  \n    
0000160                                                           p   e
0000200   r   l       -   l   e     342 200 231   p   r   i   n   t    
0000220   1 342 200 231  \n  \n                               E   n   d
0000240       o   f       t   e   s   t   i   n   g  \n  \n  \n  \n   p
0000260   e   r   l       v   5   .   8   .   8                        
0000300                                                                
0000320       2   0   0   7   -   1   0   -   1   5                    
0000340                                                                
0000360                           T   E   S   T   (   1   )  \n
0000376

When I run simple

$ pod2man test.pod

it still has the correct apostophe there:

[...]
.IX Title "TEST 1"
.TH TEST 1 "2007-10-15" "perl v5.8.8" "User Contributed Perl Documentation"
.SH "Test"
.IX Header "Test"
Testing
.PP
.Vb 1
\&        perl -le 'print 1'
.Ve
.PP
End of testing

It's only after

$ pod2man test.pod | nroff -man

when it gets changed.

So, either nroff is doing something nasty, trying to be clever and changing
characters when it shouldn't, or nroff's behaviour is documented and alright,
and then probably pod2man should do some more quoting/escaping/tweaking to
produce output which nroff will process without changing the characters.

-- 
Configure bugmail: https://bugzilla.redhat.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.

--
Fedora Extras Perl SIG
http://www.fedoraproject.org/wiki/Extras/SIGs/Perl
Fedora-perl-devel-list mailing list
Fedora-perl-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/fedora-perl-devel-list

[Index of Archives]     [Fedora Announce]     [Fedora Kernel]     [Fedora Testing]     [Fedora Legacy Announce]     [Fedora PHP Devel]     [Kernel Devel]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Big List of Linux Books]     [Gimp]     [Yosemite Information]
  Powered by Linux