Blob Blame History Raw
.\" This manpage has been automatically generated by docbook2man 
.\" from a DocBook document.  This tool can be found at:
.\" <http://shell.ipoline.com/~elmert/comp/docbook2X/> 
.\" Please send any bug reports, improvements, comments, patches, 
.\" etc. to Steve Cheng <steve@ggi-project.org>.
.TH "SGMLDIFF" "1" "11 February 2004" "" ""

.SH NAME
sgmldiff \- Find differences in the markup of two SGML files
.SH SYNOPSIS

\fBsgmldiff\fR [ \fBoptions \fR\fI ...\fR ] \fB\fIfile1\fB\fR \fB\fIfile2\fB\fR [ \fB-a\fR | \fB--attributes\fR
    | \fB-c  [ attributes | nesting | textpos ]\fR | \fB--context  [ attributes | nesting | textpos ]\fR
    | \fB-s\fR | \fB--statistics\fR
    | \fB-h\fR | \fB--help\fR
    | \fB-v\fR | \fB--version\fR ]

.SH "DESCRIPTION"
.PP
This perl script allows to determine the structural differences
between two SGML files. It compares the files, regardless of what
is in between the tags, to only focus on the markup. Its output
is similar to \fBdiff\fR(1)\&.
.PP
The typical use of \fBsgmldiff\fR is to
compare an SGML file with its translation into another language. If
the translation was done cleanly, \fBsgmldiff\fR
returns without finding any difference in the markup.
.PP
An example of a typical call to sgmldiff is:

.nf
      sgmldiff english.sgml italiano.sgml
    
.fi
.PP
If there are differences in markup between both files,
\fBsgmldiff\fR will output a series of differences
reports summarized with lines of the form:
.TP
\fB169a164\fR
At line 169 of the first file, line 164 of the
second file has been added.
.TP
\fB8a12,15\fR
At line 8 of the first file, lines 12 to 15
of the second file have been added.
.TP
\fB41d28\fR
Line 41 of the first file has been destroyed, to
obtain line 28 of the second file.
.TP
\fB63,66d61\fR
Lines 63 to 66 of the first file have been
destroyed. to obtain line 61 of the second file.
.TP
\fB52c51\fR
Line 52 of the first file has been changed into
line 51 of the second file.
.TP
\fB5,7c8,10\fR
Lines 5 to 7 of the first file have been changed
into lines 8 to 10 of the second line.
In addition to those summaries, the lines of the first file are
shown preceeded by '<' and the lines of the second file are
shown preceeded by '>".
.SH "OPTIONS"
.PP
Here is the list of actions that can be requested to
sgmldiff:
.TP
\fB             [ -a | --attributes ]  \fR
Include the attribute values in the difference tests.
Don't set this value if the attributes are likely to be
translated. Set this value if the attributes value shouldn't
change between both files. Default is to don't include the
attributes in the difference tests.
.TP
\fB             [ -c  [ attributes | nesting | textpos ] | --context  [ attributes | nesting | textpos ] ]  \fR
Add more context to the difference. Since every test between the tags is removed before testing the differences, \fBsgmldiff\fR is likely to resynchronize itself at the wrong place, by thinking the location in both files correspond, while it's not true. By adding more context to the compared area, such risk is disminished.

The allowed values for the \fB--context\fR option are:
.RS
.TP
\fBattributes\fR
Take into account the attribute
\fBnames\fR\&. The attribute
\fBvalues\fR are controlled by the
\fBattributes\fR option.
.TP
\fBnesting\fR
Take into account the nesting level of all the compared tags.
.TP
\fBtextpos\fR
Take into account the position in the text.
.RE
.TP
\fB             [ -s | --statistics ]  \fR
Print some SGML information at the end.
.TP
\fB             [ -h | --help ]  \fR
Print a short help message and exit
.TP
\fB             [ -v | --version ]  \fR
Print the version identifier and exit
.SH "FILES"
.PP
.SH "AUTHORS"
.TP
\fB          Frederik Fouvry \fR
Developer of \fBsgmldiff\fR\&.
.SH "SEE ALSO"
.TP
\fB          jw(1) \fR
conversion from a SGML file to other file formats
.TP
\fB   nsgmls(1) \fR
a base component of \fBJade\fR DSSSL engine
.TP
\fB   http://sources.redhat.com/docbook-tools/ <URL:http://sources.redhat.com/docbook-tools/> \fR
the home page of the DocBook tools, a compendium of
all tools necessary to process DocBook files, including
the DocBook-utils