niXforums Forum Index
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   PreferencesPreferences   Log in to check your private messagesLog in to check your private messages   Log inLog in 
·  nixdoc.net ·  man pages ·  Linux HOWTOs ·  FreeBSD Tips ·  Forums
navigation Forum index » Programming » Perl
pod2man newbie needs help
Post new topic   Reply to topic Page 1 of 1 [4 Posts] View previous topic :: View next topic
Author Message
bkimelman@hotmail.com
*nix forums beginner


Joined: 08 Feb 2005
Posts: 3

PostPosted: Tue Feb 08, 2005 6:04 pm    Post subject: pod2man newbie needs help Reply with quote

I decided to try and document some Perl scripts of mine using POD style
documentation. However whenever I run pod2man I receive the following
error message :

pod2man: Invalid man page - 1st pod line is not NAME in x2.pl

Here is a partial listing of x2.pl (enough to show the problem).

1 #!/usr/bin/perl -w
2
3 use Getopt::Std;
4 use strict;
5
6 my ( %options , $status );
7
8 %options = ( "d" => 0 , "n" => 0 );
9 exit 0;
10
11 __END__
12 =head1 NAME
13 A Perl script to display the requested data
14
15 =head1 SYNOPSIS
16 es.pl [-dn] lookup_value
17
18 =head1 ABSTRACT
19 This script will display environment variables in a
20 highly flexible manner.

As you can see my 1st pod line is indeed a NAME value. So what is
pod2man trying to tell me ? I looked at some other Perl modules on my
system and I am using the same style as those modules, but I am not
having any luck.

Thanks in advance for any help you can give.
Back to top
phaylon
*nix forums Guru Wannabe


Joined: 11 Apr 2005
Posts: 124

PostPosted: Tue Feb 08, 2005 6:04 pm    Post subject: Re: pod2man newbie needs help Reply with quote

bkimelman wrote:

Quote:
As you can see my 1st pod line is indeed a NAME value. So what is pod2man
trying to tell me ? I looked at some other Perl modules on my system and I
am using the same style as those modules, but I am not having any luck.

AFAIR are the docs recommending empty lines between POD-"blocks". A short
test here (line numbers are very unhandy for c&p) says the same.

g,phay

--
http://www.dunkelheit.at/
codito, ergo sum.
Back to top
bkimelman@hotmail.com
*nix forums beginner


Joined: 08 Feb 2005
Posts: 3

PostPosted: Tue Feb 08, 2005 6:16 pm    Post subject: Re: pod2man newbie needs help Reply with quote

bkimelman@hotmail.com wrote:
Quote:
I decided to try and document some Perl scripts of mine using POD
style
documentation. However whenever I run pod2man I receive the following
error message :

pod2man: Invalid man page - 1st pod line is not NAME in x2.pl

Here is a partial listing of x2.pl (enough to show the problem).

1 #!/usr/bin/perl -w
2
3 use Getopt::Std;
4 use strict;
5
6 my ( %options , $status );
7
8 %options = ( "d" => 0 , "n" => 0 );
9 exit 0;
10
11 __END__
12 =head1 NAME
13 A Perl script to display the requested data
14
15 =head1 SYNOPSIS
16 es.pl [-dn] lookup_value
17
18 =head1 ABSTRACT
19 This script will display environment variables in a
20 highly flexible manner.

As you can see my 1st pod line is indeed a NAME value. So what is
pod2man trying to tell me ? I looked at some other Perl modules on my
system and I am using the same style as those modules, but I am not
having any luck.

Thanks in advance for any help you can give.


A slight typo when I was cutting and pasting into my original post. I
do indeed have a blank line between the "__END__" and "=head1" lines as
stated in the manual page for perlpod
Back to top
Bill Smith
*nix forums beginner


Joined: 05 Feb 2005
Posts: 7

PostPosted: Tue Feb 08, 2005 9:23 pm    Post subject: Re: pod2man newbie needs help Reply with quote

<bkimelman@hotmail.com> wrote in message
news:1107889453.975555.98620@g14g2000cwa.googlegroups.com...
Quote:
I decided to try and document some Perl scripts of mine using POD
style
documentation. However whenever I run pod2man I receive the following
error message :

pod2man: Invalid man page - 1st pod line is not NAME in x2.pl

Here is a partial listing of x2.pl (enough to show the problem).

1 #!/usr/bin/perl -w
2
3 use Getopt::Std;
4 use strict;
5
6 my ( %options , $status );
7
8 %options = ( "d" => 0 , "n" => 0 );
9 exit 0;
10
11 __END__
12 =head1 NAME
13 A Perl script to display the requested data
14
15 =head1 SYNOPSIS
16 es.pl [-dn] lookup_value
17
18 =head1 ABSTRACT
19 This script will display environment variables in a
20 highly flexible manner.

As you can see my 1st pod line is indeed a NAME value. So what is
pod2man trying to tell me ? I looked at some other Perl modules on my
system and I am using the same style as those modules, but I am not
having any luck.


The NOTES section of perldoc pod2man gives the spec for developing
manpages in POD. Your NAME line does not conform to that spec. I
believe that this is your problem. I have found that POD requires
a lot of blank lines. It has to do with the fact that blank lines
are used to separate "paragraphs" as that word is used in the spec.

I find it easier to leave a blank line before and after every POD
command than to learn (and remember) the applicable rules.
The unnecessary (if any) blank lines do not appear in the manpage.

Good luck,
Bill
Back to top
Google

Back to top
Display posts from previous:   
Post new topic   Reply to topic Page 1 of 1 [4 Posts] View previous topic :: View next topic
The time now is Fri Jan 09, 2009 5:24 am | All times are GMT
navigation Forum index » Programming » Perl
Jump to:  

Similar Topics
Topic Author Forum Replies Last Post
No new posts Newbie question: How to forward a domain to a mailbox? leei Postfix 0 Fri Aug 24, 2007 4:55 pm
No new posts newbie question Miles Fidelman Debian 6 Thu Jul 20, 2006 9:20 pm
No new posts Another newbie question Mark Rae Suse 7 Thu Jul 20, 2006 3:25 pm
No new posts again a newbie... :( compiler problems Thorsten Kaben C++ 18 Thu Jul 20, 2006 2:52 am
No new posts Newbie question: Patches on CD and burning WIn CDs BertieBigBollox@gmail.com Solaris 1 Wed Jul 19, 2006 2:15 pm

Mortgages | Mobile Phones | Web Advertising | Loans | Debt Consolidation
Copyright © 2004-2005 DeniX Solutions SRL
 
Other DeniX Solutions sites: Unix/Linux blog |  electronics forum |  medicine forum |  science forum | 
Privacy Policy


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.1762s ][ Queries: 16 (0.0954s) ][ GZIP on - Debug on ]