00:00:07The purpose of this video is to demonstrate
how to generate various reports that show the
00:00:11results of a directory comparison using
scripts in a command line window.
00:00:17First I'll use the help command to display
the documentation for this script.
00:00:24And I'll paste a command for a
very simple directory comparison.
00:00:29By default, the comparison report is sent
to the standard console in YAML format.
00:00:35But, other output formats are available,
including JSON, XML, and HTML.
00:00:40I can use the -out option
to specify the format.
00:00:44For my example, I'll specify XML for the
format but I'll use the "raw" qualifier,
00:00:50which means that the detected differences
won't be grouped, and instead, simply
00:00:55listed in the order they were detected.
I can also choose to direct the results to
00:01:01an HTML output file using the -outfile option to
make the results easier to view and interpret.
00:01:07I'll open the resulting file in my browser. The
report displays information about all the detected
00:01:14differences in a user-friendly interface.
It has filtering options at the top ...
00:01:24I can click on a file links to
open the resource in the browser.
00:01:31I'll do the same for the corresponding
difference on the right side.
00:01:38I can also specify some filtering
options when I run the command.
00:01:45For example, I"ll paste a command
that will exclude JPEG files.
00:01:52If I open the resulting report file in
the browser, you can see that the Gerbera
00:01:57JPEG file that I clicked on in the last
report is now missing from the results table.
00:02:03For another example, I'll paste
a command that will include
00:02:07only files with a .dita file extension.
00:02:11If I open the resulting report file, you can see
that only "dita" resources have been compared.
00:02:19Suppose I want to exclude the "test"
directory that appears in the report.
00:02:24I can achieve that using an exclude filter.
00:02:30And when I open the corresponding report,
that difference is now excluded.
00:02:37For all pairs of modified files highlighted
in the report, it would be ideal to be able
00:02:42to concretely visualize the differences.
I can do that by using the ifcr qualifier for
00:02:49html format as noted in the help documentation.
I'll paste an example using that qualifier.
00:02:58And I'll open the resulting report file ...
... and if I click on one of the diff symbols
00:03:05in the middle cells, a new report is opened with
details only about that specific difference.
00:03:14That qualifier option also creates
a new directory that contains the
00:03:18additional file comparison reports.
00:03:25The 3-way directory comparison mode is also
available. I simply need to specify the paths
00:03:31of the 2 directories to be compared, immediately
followed by the path to the base directory.
00:03:38I'll open the resulting report.
I can click on the diff symbol in one
00:03:43of the middle cells to open a report of
the differences for that file pair.
00:03:52I can use filtering options in my
command to filter differences.
00:04:00And I'll open the resulting report and if
I click on the symbol in the middle cell,
00:04:04you see that there are now fewer differences.
00:04:09The concept of merging "incoming" differences
also applies to 3-way directory comparisons.
00:04:15In this case, you see the
results in the console ...
00:04:19and it also results in a newly created
directory called merge-output,
00:04:27and you can see that its structure is based upon
the results of the merge operation and
00:04:32the information in both of them corresponds to
the differences we saw in the HTML report.
00:04:39As you can see, there are a lot
of different options that you have
00:04:42available to refine the HTML reports
to suit your specific needs.
00:04:47This concludes the demonstration.
Thank you for watching.