=================================================================== RCS file: /cvs/docbook2mdoc/docbook2mdoc.1,v retrieving revision 1.11 retrieving revision 1.13 diff -u -p -r1.11 -r1.13 --- docbook2mdoc/docbook2mdoc.1 2019/04/09 16:57:29 1.11 +++ docbook2mdoc/docbook2mdoc.1 2019/04/23 15:47:23 1.13 @@ -1,4 +1,4 @@ -.\" $Id: docbook2mdoc.1,v 1.11 2019/04/09 16:57:29 schwarze Exp $ +.\" $Id: docbook2mdoc.1,v 1.13 2019/04/23 15:47:23 schwarze Exp $ .\" .\" Copyright (c) 2014 Kristaps Dzonsons .\" Copyright (c) 2019 Ingo Schwarze @@ -15,7 +15,7 @@ .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. .\" -.Dd $Mdocdate: April 9 2019 $ +.Dd $Mdocdate: April 23 2019 $ .Dt DOCBOOK2MDOC 1 .Os .Sh NAME @@ -24,6 +24,7 @@ .Sh SYNOPSIS .Nm docbook2mdoc .Op Fl W +.Op Fl T Cm mdoc | tree | lint .Op Ar file .Sh DESCRIPTION The @@ -40,8 +41,36 @@ is .Sq Cm \- or omitted, standard input is used. .Pp -The arguments are as follows: -.Bl -tag -width Ds +The options are as follows: +.Bl -tag -width 2n +.It Fl T +Select the output mode. +The following arguments are supported: +.Bl -tag -width 4n +.It Cm mdoc +Translate the input to +.Xr mdoc 7 . +This is the default. +.It Cm tree +Dump a human-readable representation of the parse tree. +Each output line shows one tree node. +Child nodes are indented with respect to their parent node. +The columns are: +.Bl -enum -width 2n +.It +A hyphen if the node follows the previous node +without intervening whitespace. +.It +The node type. +.It +For text nodes, the text contents. +For other nodes, the attributes, if any. +.El +.It Cm lint +Do not produce any output, only error messages. +Can be combined with +.Fl W . +.El .It Fl W Report warnings on standard error output, and if any occur, raise the .Sx EXIT STATUS @@ -72,6 +101,16 @@ Internal subset declaration to define an XML entity. .Ec > Internal subset declaration to define an XML entity using an external .Ar file . +.It Eo +.Pf % Ar name No \& +.Bc +.Ec > +Internal subset declaration to include an external +.Ar file +that is supposed to contain entity declarations. .It Eo < Ic mml : Ns ... Ec > Elements from the MathML namespace. These are translated to