[Pkg-emboss-commits] r59 - emboss/trunk/debian
charles-guest at alioth.debian.org
charles-guest at alioth.debian.org
Sat Jul 7 06:20:43 UTC 2007
Author: charles-guest
Date: 2007-07-07 06:20:42 +0000 (Sat, 07 Jul 2007)
New Revision: 59
Modified:
emboss/trunk/debian/acd2docbook.pl
Log:
First working version
Modified: emboss/trunk/debian/acd2docbook.pl
===================================================================
--- emboss/trunk/debian/acd2docbook.pl 2007-07-05 15:35:03 UTC (rev 58)
+++ emboss/trunk/debian/acd2docbook.pl 2007-07-07 06:20:42 UTC (rev 59)
@@ -1,5 +1,13 @@
#!/usr/bin/perl
+# acd2docbook.pl was made for Debian by Charles Plessy in 2007, and can be
+# used, modified and redistributed as if it were in the public domain.
+#
+# You can report bugs to bugs.debian.org/emboss, and access the latest version here:
+# http://svn.debian.org/wsvn/pkg-emboss/emboss/trunk/debian/acd2docbook.pl?op=file&rev=0&sc=0
+#
+# Many thanks to David Bauer for the original idea.
+
use strict;
use warnings;
@@ -16,8 +24,8 @@
my $NAME = $name;
$NAME =~ s/(.)/\U$1/g;
my $purpose = $acd->documentation;
+my $groups = join(",", $acd->groups);
-
foreach my $parameter( $acd->param) {
foreach my $key (keys( %$parameter)) {
print STDERR $key, " -- ", $$parameter{$key},"\n";
@@ -83,57 +91,28 @@
<refsynopsisdiv>
<cmdsynopsis>
<command>&dhpackage;</command>
- <arg choice="opt"><option>-bar</option></arg>
- <group choice="opt">
- <arg choice="plain"><option>-b</option></arg>
- <arg choice="plain"><option>--busy</option></arg>
- </group>
- <group choice="opt">
- <arg choice="plain"><option>-c <replaceable>config-file</replaceable></option></arg>
- <arg choice="plain"><option>--config=<replaceable>config-file</replaceable></option></arg>
- </group>
- <arg choice="opt">
- <group choice="req">
- <arg choice="plain"><option>-e</option></arg>
- <arg choice="plain"><option>--example</option></arg>
- </group>
- <replaceable class="option">this</replaceable>
- </arg>
- <arg choice="opt">
- <group choice="req">
- <arg choice="plain"><option>-e</option></arg>
- <arg choice="plain"><option>--example</option></arg>
- </group>
- <group choice="req">
- <arg choice="plain"><replaceable>this</replaceable></arg>
- <arg choice="plain"><replaceable>that</replaceable></arg>
- </group>
- </arg>
- <arg choice="plain" rep="repeat"><replaceable>file(s)</replaceable></arg>
+__XML__
+
+foreach my $parameter ( $acd->param) {
+ next if $$parameter{datatype} =~ /section/;
+ my ($paraname, $argname, $paratype) = ( $$parameter{name}, $$parameter{datatype}, $$parameter{type} );
+ my $additional = 'choice="plain"';
+ $additional = 'choice="opt"' if $$parameter{additional} eq 'Y';
+ print qq(\t\t\t<arg $additional><option>-$paraname <replaceable>$argname</replaceable></option></arg>\n);
+}
+
+
+print <<"__XML__";
</cmdsynopsis>
<cmdsynopsis>
<command>&dhpackage;</command>
- <!-- Normally the help and version options make the programs stop
- right after outputting the requested information. -->
- <group choice="opt">
- <arg choice="plain">
- <group choice="req">
- <arg choice="plain"><option>-h</option></arg>
- <arg choice="plain"><option>--help</option></arg>
- </group>
- </arg>
- <arg choice="plain">
- <group choice="req">
- <arg choice="plain"><option>-v</option></arg>
- <arg choice="plain"><option>--version</option></arg>
- </group>
- </arg>
- </group>
+ <arg choice="plain"><option>-help</option></arg>
</cmdsynopsis>
</refsynopsisdiv>
<refsect1 id="description">
<title>DESCRIPTION</title>
- <para><command>&dhpackage;</command> frobnicates the <application>bar</application> library by tweaking internal symbol tables. By default it parses all baz segments and rearranges them in reverse order by time for the <citerefentry><refentrytitle>xyzzy</refentrytitle><manvolnum>1</manvolnum></citerefentry> linker to find them. The symdef entry is then compressed using the <abbrev>WBG</abbrev> (Whiz-Bang-Gizmo) algorithm. All files are processed in the order specified.</para>
+ <para><command>&dhpackage;</command> is a command line program from the EMBOSS software suite. It is part of the "$groups" command group(s).
+ </para>
</refsect1>
<refsect1 id="options">
@@ -157,96 +136,35 @@
next;
}
+ # Is there a Default value ?
+ my $default;
+ $default = " Default value: $$parameter{default}." unless $$parameter{default} eq 'N';
+
print<<"__XML__";
<varlistentry>
- <term><option>-$$parameter{name}</option></term>
+ <term>
+ <option>-$$parameter{name}</option>
+ <parameter>$$parameter{datatype}</parameter>
+ </term>
<listitem>
- <para>$$parameter{datatype}</para>
+ <para>$$parameter{help}$default</para>
</listitem>
</varlistentry>
__XML__
}
-
-
print<<"__XML__";
</refsect1>
- <refsect1 id="files">
- <title>FILES</title>
- <variablelist>
- <varlistentry>
- <term><filename>/etc/foo.conf</filename></term>
- <listitem>
- <para>The system-wide configuration file. See <citerefentry><refentrytitle>foo.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry> for further details.</para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><filename>\${HOME}/.foo.conf</filename></term>
- <listitem>
- <para>The per-user configuration file. See <citerefentry><refentrytitle>foo.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry> for further details.</para>
- </listitem>
- </varlistentry>
- </variablelist>
- </refsect1>
- <refsect1 id="environment">
- <title>ENVIONMENT</title>
- <variablelist>
- <varlistentry>
- <term><envar>FOOCONF</envar></term>
- <listitem>
- <para>The full pathname for an alternate system wide configuration file <citerefentry><refentrytitle>foo.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry> (see also <xref linkend="files"/>). Overridden by the <option>-c</option> option.</para>
- </listitem>
- </varlistentry>
- </variablelist>
- </refsect1>
- <refsect1 id="diagnostics">
- <title>DIAGNOSTICS</title>
- <para>The following diagnostics may be issued on <filename class="devicefile">stderr</filename>:</para>
- <variablelist>
- <varlistentry>
- <term><quote><errortext>Bad magic number.</errortext></quote></term>
- <listitem>
- <para>The input file does not look like an archive file.</para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><quote><errortext>Old style baz segments.</errortext></quote></term>
- <listitem>
- <para><command>&dhpackage;</command> can only handle new style baz segments. <acronym>COBOL</acronym> object libraries are not supported in this version.</para>
- </listitem>
- </varlistentry>
- </variablelist>
- <para>The following return codes can be used in scripts:</para>
- <segmentedlist>
- <segtitle>Errorcode</segtitle>
- <segtitle>Errortext</segtitle>
- <segtitle>Diagnostic</segtitle>
- <seglistitem>
- <seg><errorcode>0</errorcode></seg>
- <seg><errortext>Program exited normally.</errortext></seg>
- <seg>No error. Program ran successfully.</seg>
- </seglistitem>
- <seglistitem>
- <seg><errorcode>1</errorcode></seg>
- <seg><errortext>Bad magic number.</errortext></seg>
- <seg>The input file does not look like an archive file.</seg>
- </seglistitem>
- <seglistitem>
- <seg><errorcode>2</errorcode></seg>
- <seg><errortext>Old style baz segments.</errortext></seg>
- <seg><command>&dhpackage;</command> can only handle new style baz segments. <acronym>COBOL</acronym> object libraries are not supported in this version.</seg>
- </seglistitem>
- </segmentedlist>
- </refsect1>
+
<refsect1 id="bugs">
<!-- Or use this section to tell about upstream BTS. -->
<title>BUGS</title>
- <para>The command name should have been chosen more carefully to reflect its purpose.</para>
- <para>The upstreams <acronym>BTS</acronym> can be found at <ulink url="http://bugzilla.foo.tld"/>.</para>
+ <para>Bugs can be reported to the Debian But Tracking system (http://bugs.debian.org/emboss), or directly to the EMBOSS developpers (http://sourceforge.net/tracker/?group_id=93650&atid=605031).</para>
</refsect1>
+
<refsect1 id="see_also">
<title>SEE ALSO</title>
- <para>The programs are documented fully via the <application>tfm</application> system.</para>
+ <para>&dhpackage; is fully documented via the <citerefentry><refentrytitle>tfm</refentrytitle><manvolnum>1</manvolnum></citerefentry> system.</para>
</refsect1>
</refentry>
__XML__
More information about the Pkg-emboss-commits
mailing list